<template>
	<view class="bg">
		<!-- #ifdef APP-PLUS || H5 -->
		<view class="top-view"
			:style="{ height: CustomBarRpx + 'rpx', paddingTop: StatusBarRpx + 'rpx', background: backgroundBar }">
		<!-- #endif -->
			<!-- #ifdef MP-WEIXIN -->
			<view class="top-view"
				:style="{ height: CustomBarRpx + 80 + 'rpx', paddingTop: StatusBarRpx + 'rpx', background: backgroundBar }">
			<!-- #endif -->
				<view class="free free0">
					<view class="flxd-img-view" v-show="!orderShow">
						<image src="../../static/image/enimg/drawing3.png" @click="couponshow = !couponshow; lingquan()"
							mode="">
						</image>
						<view class="dot-red" v-if="couponList.length > 0">{{ couponList.length }}</view>
					</view>
				</view>
				<view class="free free1">
					<view class="flxd-img-view" v-show="!orderShow">
						<image src="../../static/image/enimg/drawing2.png" @click="daojushow = true; getCard()" mode="">
						</image>
						<view class="dot-red" v-if="cardList.length > 0">{{ cardList.length }}</view>
					</view>
				</view>
<!-- 				<view class="free free2" v-show="!orderShow">
					<image src="../../static/image/enimg/freePlay.png" @click="shiwan" mode="">
					</image>
				</view> -->

				<!-- <image v-show="!orderShow" class="invite"
					src="https://img.alicdn.com/imgextra/i1/2215984279448/O1CN01K3UHgd2JfEwByG8pR_!!2215984279448.png"
					@click="$.to('/pagesA/pages/my/yaoqing')" mode="widthFix">
				</image> -->
				<image v-show="!orderShow" class="invite"
				    src="../../static/image/new/1-removebg-preview.png"
					@click="$.to('/pagesA/pages/my/yaoqing')" mode="widthFix">
				</image>
				
				<image v-show="!orderShow" class="playBtn"
					src="../../static/image/new/2-removebg-preview.png"
					@click="$.to('/pages/my/agreement?type=play_agreement')" mode="">
				</image>
				
				<!-- <image v-show="!orderShow" class="playBtn"
					src="https://img.alicdn.com/imgextra/i2/2215984279448/O1CN01kY0vuD2JfEwHeLvGH_!!2215984279448.png"
					@click="$.to('/pages/my/agreement?type=play_agreement')" mode="">
				</image> -->

				<image v-show="!orderShow" :class="muteBgMusic ? 'music stop' : 'music'"
					:src="muteBgMusic ? 'https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/drawing136eef561718eee2a9.png' : 'https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/drawing6.png'"
					mode="" @click="playMusic"></image>
				<template v-if="showTitle">
					<view class="icon_setUp showTitle-view" style="padding-left: 20rpx">
						<view style="width: 100rpx;"><u-icon name="arrow-left" @click="back" size="40rpx"></u-icon>
						</view>
						<!-- #ifdef MP-WEIXIN -->
						<view class="showTitle-2 showTitle-2-mapwx">{{ boxInfo.title }}</view>
						<view style="width: 100rpx;"></view>
						<!-- #endif -->
						<!-- #ifdef APP-PLUS || H5 -->
						<view class="showTitle-2">{{ boxInfo.title }}</view>
						<view class="showTitle" style="width: 100rpx;">
							<!-- #ifdef APP-PLUS -->
							<view @click="wxKefu" class="kfclass">
								<!-- {{$t('联系客服')}} -->
								<!-- <u-icon name="photo"></u-icon> -->
								<image src="../../static/image/kf.png" mode="widthFix"></image>
							</view>
							<!-- #endif -->
							<!-- #ifdef MP-WEIXIN -->
							<view @click="openServer" class="kfclass">
								<button class="kf-button" open-type="contact">
									<!-- {{$t('联系客服')}} -->
									<image src="../../static/image/kf.png" mode="widthFix"></image>
								</button>
							</view>
							<!-- #endif -->
							<!-- #ifdef H5 -->
							<view @click="openServer" class="kfclass">
								<!-- {{$t('联系客服')}} -->
								<image src="../../static/image/kf.png" mode="widthFix"></image>
							</view>
							<!-- #endif -->
						</view>
						<!-- #endif -->
					</view>
					<!-- #ifdef MP-WEIXIN -->
					<view class="logoName">
						<!-- <view class="logoName_left" style="padding-left: 20rpx">{{ boxInfo.title }}</view> -->
						<view class="logoName_left" style="padding-left: 20rpx"></view>
						<view class="logoName_right" style="padding-right: 20rpx">
							<!-- #ifdef APP-PLUS -->
							<view @click="wxKefu" class="kfclass">
								<!-- {{$t('联系客服')}} -->
								<image src="../../static/image/kf.png" mode="widthFix"></image>
							</view>
							<!-- #endif -->
							<!-- #ifdef MP-WEIXIN -->
							<view @click="openServer" class="kfclass">
								<button class="kf-button" open-type="contact">
									<!-- {{$t('联系客服')}} -->
									<image src="../../static/image/kf.png" mode="widthFix"></image>
								</button>
							</view>
							<!-- #endif -->
							<!-- #ifdef H5 -->
							<view @click="openServer" class="kfclass">
								<!-- {{$t('联系客服')}} -->
								<image src="../../static/image/kf.png" mode="widthFix"></image>
							</view>
							<!-- #endif -->
						</view>
					</view>
					<!-- #endif -->
				</template>
				<template v-else>
					<view class="icon_setUp">
						<u-icon name="arrow-left" style="margin-left: 30rpx" size="30rpx" @click="back"></u-icon>
						<view class="boxList-title-0">
							<view class="b-0-0">{{$t('开盒必出以下宝贝之一')}}</view>
							<view class="b-0-1">{{$t('抽到不满意可兑换')}}</view>
						</view>
					</view>

					<view class="logoName" v-if="is_baodi === 1" @click="showBaodi = true">
						<view class="boxList-title-1">
							<view class="boxList-title-1-left">
								{{ baodi_name }}
							</view>
							<view class="boxList-title-1-right">{{$t('已抽')}} {{ baodi_ucount || 0 }}/{{ baodi_zcount }}
							</view>
						</view>
					</view>
				</template>
			</view>
			<view v-for="(tong, index) in tongView" :key="index"
				:class="tong.level_name === '史诗' ? 'tong-view tong-view-ssbg' : 'tong-view tong-view-csbg'"
				@click="openTong(tong)">
				<view class="tong-view-text" @click="openTong(tong)">{{ tong.text }}</view>
				<image :src="tong.goods_image" class="tong-gd-img" mode="scaleToFill" @click="openTong(tong)"></image>

<!-- 				<view class="text-gd-img" v-if="tong.level_name === '史诗'" style="color: #ef2a2a">
					<image
						src="http://v3mh6.oss-cn-beijing.aliyuncs.com/uploads/20240109/43b9a16489a48d2e647d2272e01db860.png"
						mode="scaleToFill"></image>
				</view>
				<view class="text-gd-img" v-if="tong.level_name == '传说'" style="color: #eb6c0a">
					<image
						src="http://v3mh6.oss-cn-beijing.aliyuncs.com/uploads/20240109/53f32f05e931318581bf08f075b12e29.png"
						mode="scaleToFill"></image>
				</view>
				<view class="text-gd-img" v-if="tong.level_name == '稀有'" style="color: #eb6c0a">
					<image src="/static/image/xiyou.png" mode="scaleToFill"></image>
				</view> -->
			</view>
			<view class="banner">
				<view :style="{ height: CustomBarRpx + 100 + 'rpx', paddingTop: StatusBarRpx + 'rpx' }"></view>
				<view class="banner-view">
					<swiper :autoplay="true" style="height: 100%">
						<swiper-item class="banner-view-item" v-for="(item, idx) in boxList" :key="idx">
							<view class="b-i-img">
								<image :src="item.goods_image" mode="widthFix"></image>
							</view>
<!-- 							<view class="b-i-role">
								<image :src="item.odd_image" mode="widthFix"></image>
							</view> -->
							<view class="b-i-title">{{ item.title }}</view>
							<view class="b-i-price">
								{{$t('¥')}}
								<text style="font-size: 36rpx">{{ parseFloat(item.goods_price).toFixed(2) }}</text>
							</view>
						</swiper-item>
					</swiper>
				</view>
			</view>

			<view class="boxList" id="demo">
				<view class="boxList-title">
					<view class="boxList-title-0">
						<view class="b-0-0">{{$t('开盒必出以下宝贝之一')}}</view>
						<view class="b-0-1">{{$t('抽到不满意可兑换')}}</view>
					</view>
					<view class="boxList-title-1" v-if="is_baodi === 1" @click="showBaodi = true">
						<view class="boxList-title-1-left">
							{{ baodi_name }}
							<!-- <view class="boxList-title-1-left-0">保底</view> -->
						</view>
						<view class="boxList-title-1-right">{{$t('已抽')}} {{ baodi_ucount || 0 }}/{{ baodi_zcount }}
						</view>
					</view>
				</view>

				<view class="boxList-odds">
<!-- 					<view class="boxList-odds-0">
						<view class="boxList-odds-left">
							<text>{{$t('获得')}}</text>
							<text>{{$t('概率')}}</text>
						</view>
						<view class="boxList-odds-right">
							<view class="boxList-odds-right-item" v-for="item in blind_box_odds" :key="item.id">
								<view class="t-i">{{ item.title }}{{$t('款')}}</view>
								<view class="b-i">{{ item.rate }}%</view>
							</view>
						</view>
					</view> -->
					<view class="boxList-odds-1">{{$t('因概率对小数点后三位进行四舍五入处理，故存在总值不为100%的可能')}}</view>
				</view>

				<view class="mh-goods-list">
					<view class="mh-goods-list-item" v-for="(item, idx) in boxList" @click="showAll(idx, item)"
						:key="idx">
						<!-- <image :src="item.odd_image" class="mh-goods-rate" mode="widthFix"></image> -->
						<view class="mh-goods-img-view">
							<!-- <image :src="item.goods_image" class="mh-goods-img"></image> -->
							<image :src="item.goods_image" class="mh-goods-img"></image>
						</view>
						<view class="mh-goods-name">{{ item.title }}</view>
						<view class="mh-goods-price">
							<text>{{$t('参考价')}}：</text>
							{{$t('¥')}}{{ parseFloat(item.goods_price).toFixed(2) }}
						</view>
						<view class="mh-goods-range" v-show="isRange">
							{{$t('抽中范围')}}：{{ item.range }}
						</view>
					</view>
				</view>
			</view>

			<view style="height: 200rpx"></view>
			<!-- // 来源 5新人活动 6买1送1 7免单白嫖 // 今日限定暂定8 -->
			<view class="bottom-view bottom-view-5" @click="choujiang()" v-if="!boxSource">{{$t('立即开箱')}}</view>
			<view class="bottom-view bottom-view-1" @click="choujiang()" v-if="boxSource == 5"></view>
			<view class="bottom-view bottom-view-3 bottom-view-2" @click="choujiang()" v-else-if="boxSource == 6">
				<view class="bottom-view-2-0">{{$t('买1送1')}} <text>{{$t('¥')}}{{ activebox.price }}</text></view>
				<view class="bottom-view-2-positon">{{$t('新人福利')}}</view>
			</view>
			<view class="bottom-view bottom-view-3 bottom-view-4" @click="choujiang()"
				v-else-if="boxSource == 7 && activebox.blind_box">
				<view class="bottom-view-4-0">{{$t('限时免单')}}</view>
				<text class="bottom-view-4-1">{{ activebox.blind_box.info }}</text>
				<view class="bottom-view-4-positon">{{$t('幸运免单')}}</view>
			</view>
			<!-- 聚划算 -->
			<view class="bottom-view bottom-view-4" @click="choujiang()"
				v-if="activebox.type == 2 && (boxSource == 8 || boxSource == 9)">
				<view class="bottom-view-4-0">{{$t('立即开盒')}}</view>
				<text class="bottom-view-4-1">
					{{$t('折后')}}<text class="yuan">{{ activebox.price }}</text>
					<text class="labei-text" style="margin-left: 6px;">
						{{ activebox.old_price }}
					</text>
				</text>
				<view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
			</view>
			<!-- 买N送N -->
			<view class="bottom-view bottom-view-4" @click="choujiang()"
				v-if="activebox.type == 6 && (boxSource == 8 || boxSource == 9)">
				<view class="bottom-view-4-0">{{$t('立即开盒')}}</view>
				<text class="bottom-view-4-1">
					<text class="yuan">{{ Number(activebox.blind_box.price).toFixed(2) }}</text>
					<text class="label-chou" v-if="boxSource == 8">
						({{$t('买')}}{{ activebox && activebox.week_info && activebox.week_info.buy_num }}{{$t('送')}}{{ activebox &&
        activebox.week_info
        && activebox.week_info.zsbuy_num }})
					</text>
					<text class="label-chou" v-if="boxSource == 9">
						({{$t('买')}}{{ activebox && activebox.activity_info && activebox.activity_info.buy_num }}{{$t('送')}}{{ activebox &&
        activebox.activity_info
        && activebox.activity_info.zsbuy_num }})
					</text>
				</text>
				<view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
			</view>
			<!-- 首单N元 -->
			<view class="bottom-view bottom-view-4" @click="choujiang()"
				v-if="activebox.type == 4 && (boxSource == 9 || boxSource == 8)">
				<view class="bottom-view-4-0">{{$t('立即开盒')}}</view>
				<text class="bottom-view-4-1">
					{{$t('首抽')}}<text class="yuan" v-if="boxSource == 8">{{ activebox.week_info.first_beishu }}</text>
					<text class="yuan" v-if="boxSource == 9">{{ activebox.activity_info.first_beishu }}</text>
					<text class="labei-text" style="margin-left: 6px;">
						{{ Number(activebox.blind_box.price).toFixed(2) }}
					</text>
					<text class="label-chou" v-if="boxSource == 8">
						({{ activebox && activebox.week_info && activebox.week_info.first_num }}{{$t('抽起购')}})
					</text>
					<text class="label-chou" v-if="boxSource == 9">
						({{ activebox && activebox.activity_info && activebox.activity_info.first_num }}{{$t('抽起购')}})
					</text>
				</text>
				<view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
			</view>
			<!-- 加1元发送N -->
			<view class="bottom-view bottom-view-4" @click="choujiang()"
				v-if="activebox.type == 5 && (boxSource == 9 || boxSource == 8)">
				<view class="bottom-view-4-0">{{$t('立即开盒')}}</view>
				<text class="bottom-view-4-1">
					<text class="yuan">{{ activebox.price }}</text>
					<text class="label-chou" v-if="boxSource == 8">
						({{$t('买1送')}}{{ activebox && activebox.week_info && activebox.week_info.zsnum }})
					</text>
					<text class="label-chou" v-if="boxSource == 9">
						({{$t('买1送')}}{{ activebox && activebox.activity_info && activebox.activity_info.zsnum }})
					</text>
				</text>
				<view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
			</view>
			<!-- N倍送 -->
			<view class="bottom-view bottom-view-4" @click="choujiang()"
				v-if="activebox.type == 3 && (boxSource == 9 || boxSource == 8)">
				<view class="bottom-view-4-0">{{$t('立即开盒')}}</view>
				<text class="bottom-view-4-1">
					<text class="yuan">{{$t('¥')}} {{ activebox.price }}</text>
					<text class="label-chou">
						({{$t('买1送')}}{{ activebox && activebox.week_info && activebox.week_info.beishu }})
					</text>
				</text>
				<view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
			</view>
			<!-- <view class="bottom-view bottom-view-4" @click="choujiang()" v-else-if="boxSource == 8">
        <view class="bottom-view-4-0">立即开盒</view>
        <text class="bottom-view-4-1">{{$t('¥')}}{{ activebox.price }}</text>
        <view class="bottom-view-4-positon">{{ activebox.sub_title }}</view>
      </view>
      <view class="bottom-view bottom-view-5" @click="choujiang()" v-else>立即开箱</view> -->
			<!-- <view class="bottom-view" @click="choujiang" v-else-if="">立即开箱</view> -->

			<!-- 道具卡 -->
			<u-popup v-model="daojushow" mode="center">
				<view class="box11">
					<view class="daojubox">
						<view class="top">
							<image :src="isCard ? '../../static/image/qp.png' : '../../static/image/qn.png'"
								mode="widthFix"></image>
							<view class="rulebox" v-if="isCard" @click="go_prop_card_rule">
								<view class="wen">?</view>
								{{$t('使用规则')}}
							</view>
						</view>
						<view v-if="isCard">
							<scroll-view scroll-y style="height: 755rpx; width: 100%; margin-top: 30rpx">
								<view class="cardList">
									<view class="list" v-for="(item, idx) in cardList" :key="idx">
										<view class="goods n-flex-row">
											<view class="picbox">
												<image :src="item.card_data.image" mode=""></image>
											</view>
											<view class="textbox">
												<view class="tit">
													{{ item.card_data.title }}
												</view>
												<view class="two">{{ item.card_data.introduce }}</view>
												<view class="qi n-flex-row n-justify-between">
													<view>
														{{$t('领取时间')}}:{{ $u.timeFormat(item.create_time, 'yyyy-mm-dd hh:MM:ss') }}
													</view>
												</view>
											</view>
										</view>
										<view class="tip1">
											{{ item.introduce }}
										</view>
									</view>
								</view>
								<u-empty :text="$t('暂无道具卡')" mode="favor" color="#766ed0" icon-color="#766ed0"
									:show="cardShow"></u-empty>
							</scroll-view>
						</view>

						<view v-else class="explain">
							<view class="tit">
								♦
								<text>{{$t('重抽卡')}}</text>
								♦
							</view>
							<scroll-view scroll-y class="text" style="height: 560rpx">{{$t('内容')}}</scroll-view>
							<view class="btm">
								<view class="btn2" @click="isCard = true">{{$t('我知道了')}}</view>
							</view>
						</view>
					</view>
					<view class="off">
						<image @click="daojushow = false" src="http://mhimg.69box.cn/kaixiang/down.png" mode=""></image>
					</view>
				</view>
			</u-popup>
			<!-- 优惠券弹窗 -->
			<u-popup v-model="couponshow" mode="center" :custom-style="{ backgroundColor: 'rgba(0, 0, 0, 0)' }">
				<view class="newPeopleBox">
					<view class="newmainBox">
						<scroll-view scroll-y class="youhuilist" v-if="couponList.length > 0">
							<view class="youhuibox" v-for="(item, idx) in couponList" :key="idx">
								<view class="left">
									<view>
										<view class="name">{{ item.name }}</view>
										<view class="price1" v-if="item.threshold_type == 2">{{$t('无门槛')}}</view>
										<view class="price1" v-if="item.threshold_type == 1 && item.join_type == 1">
											<block v-if="item.type == 1">
												{{$t('满')}}{{ item.threshold_money }}{{$t('可用')}}
											</block>
											<block v-if="item.type == 2">{{ item.discount }}{{$t('折')}}</block>
										</view>
										<view class="price1" v-if="item.threshold_type == 1 && item.join_type == 2">
											{{$t('盲盒专享')}}
										</view>
									</view>
								</view>
								<view class="right">
									<view>
										<view class="price">
											<template v-if="item.type == 1">{{$t('¥')}}{{ item.amount }}</template>
											<template v-if="item.type == 2">{{ item.discount }}{{$t('折')}}</template>
										</view>
										<!-- <view class="ling active" @click="receive(item.id, item.is_lingqu, idx)">领取</view> -->
										<!-- <view class="ling" :class="item.is_lingqu == 0 ? 'active' : 'yiling'" @click="receive(item.id, item.is_lingqu, idx)">
   								{{ item.is_lingqu == 0 ? '领取' : '已领取' }}
   							</view> -->
									</view>
								</view>
							</view>
						</scroll-view>
						<view class="youhuilist" v-else>
							<u-empty :text="$t('暂无可领取的优惠券')" mode="coupon"></u-empty>
						</view>
					</view>
					<view class="btm-2" style="ma">
						<image class="btmBg" src="http://m-oss.mhbox.top/uploads/20241208/431eeea92587a62a6fef1f8899738f55.pngp" mode="widthFix"></image>
						<view class="btn1">
							<image v-if="couponList.length > 0" @click="receive(1)"
								src="http://m-oss.mhbox.top/uploads/20241211/f60d5fee8cd358592b8eba5a9bef27fe.PNG" mode="widthFix"></image>
						</view>
					</view>

					<view class="off">
						<image @click="couponshow = false" src="http://m-oss.mhbox.top/uploads/20241208/618d834aa2bf39cec0a4a3ae81d6bd11.png" mode="">
						</image>
					</view>
				</view>
			</u-popup>

			<!-- 选择抽奖盒数-->
			<u-popup v-model="luckshow" mode="center">
				<view class="luckbox">
					<view class="top n-flex-row">
						<image class="titpic" src="../../static/image/enimg/lucktit.png" mode="widthFix">
						</image>
						<image class="goodsPic" :src="boxInfo.footer_image" mode="widthFix"></image>
					</view>
					<view class="option">

						<view class="row">
							<view class="chou" v-for="(buyFa, idx) in boxInfo.buy_data1" :key="buyFa.id"
								v-if="idx === 0 || idx === 1" @click="chou(buyFa.number, buyFa.youhui_num)">
								<view class="jian" v-if="buyFa.youhui_title">{{ buyFa.youhui_title }}</view>
								<view class="b">
									<view class="tit" style="line-height: 1em;">{{ buyFa.title }}</view>
									<view v-if="!isShiwan && boxInfo.xryh != 1" style="padding-bottom: 10rpx;">
										{{$t('¥')}}{{ buyFa.buy_price }}
										<text class="yuanj" v-if="buyFa.youhui_title">{{$t('¥')}}{{ ((buyFa.buy_price * 1000) + (buyFa.youhui_num *
        1000)) / 1000 }}</text>
									</view>
								</view>
							</view>
						</view>
						<view class="row">
							<view class="chou" v-for="(buyFa, idx) in boxInfo.buy_data1" :key="buyFa.id"
								v-if="idx === 2 || idx === 3" @click="chou(buyFa.number, buyFa.youhui_num)">
								<view class="jian" v-if="buyFa.youhui_title">{{ buyFa.youhui_title }}</view>
								<view class="b">
									<view class="tit" style="line-height: 1em;">{{ buyFa.title }}</view>
									<view v-if="!isShiwan && boxInfo.xryh != 1" style="padding-bottom: 10rpx;">
										{{$t('¥')}}{{ buyFa.buy_price }}
										<text class="yuanj" v-if="buyFa.youhui_title">{{$t('¥')}}{{ ((buyFa.buy_price * 1000) + (buyFa.youhui_num *
        1000)) / 1000 }}</text>
									</view>
								</view>
							</view>
						</view>
					</view>
				</view>
			</u-popup>

			<!-- 订单 -->
			<u-popup v-model="orderShow" mode="bottom" :closeable="!selectCoupon">
				<view class="orderbox" v-if="!selectCoupon">
					<view class="tit">{{$t('确认订单')}}</view>
					<view class="con">
						<view class="box1">
							<view class="goods n-flex-row">
								<image :src="boxInfo.image" mode=""></image>
								<view class="info">
									<view class="t" style="font-size: 28rpx">{{ boxInfo.title }}</view>
									<view style="font-size: 24rpx; margin-top: 10rpx; color: #999;">{{ boxInfo.info }}
									</view>
									<view class="two">
										<view class="price" v-if='confrimView.source == 5 || confrimView.source == 6'>
											{{$t('¥')}}{{ boxPrice
                      }}</view>
										<!-- 限时活动 -->
										<!-- <view class="price" v-if="confrimView.source == 9 && confrimView.type == 2">
											<text class="pay_price">{{$t('¥')}}{{ activebox.price }}</text>
											<text class="old_price song-text">(买{{ activebox && activebox.activity_info && activebox.activity_info.buy_num }}送{{ activebox &&
				activebox.activity_info
				&& activebox.activity_info.zsbuy_num }})</text>
										</view> -->
										<view class="price"
											v-if="confrimView.type == 2 && (confrimView.source == 9 || confrimView.source == 8)">
											<text class="pay_price">{{$t('折后')}}{{$t('¥')}}{{ activebox.price }}</text>
											<text class="old_price">{{ boxPrice }}</text>
										</view>
										<!-- 加1元发送N -->
										<view class="price"
											v-if="confrimView.type == 5 && (confrimView.source == 9 || confrimView.source == 8)">
											<text class="pay_price">{{$t('¥')}}{{ activebox.price }}</text>
											<text class="old_price song-text" v-if="boxSource == 8">({{$t('买1送')}}{{
        confrimView.week_info.zsnum
      }})</text>
											<text class="old_price song-text" v-if="boxSource == 9">({{$t('买1送')}}{{
        confrimView.activity_info.zsnum
      }})</text>
										</view>
										<!-- N倍送 -->
										<view class="price" v-if="confrimView.type == 3">
											<text class="pay_price">{{$t('¥')}}{{ activebox.price }}</text>
											<text class="old_price song-text">({{$t('买1送')}}{{ confrimView.week_info.zsnum
                        }})</text>
										</view>
										<!-- 首单N元 -->
										<view class="price"
											v-if="confrimView.type == 4 && (confrimView.source == 9 || confrimView.source == 8)">
											<text style="font-weight: 400;">{{$t('首抽')}}</text>
											<text class="pay_price" v-if="boxSource == 8">{{$t('¥')}}{{
        activebox.week_info.first_beishu
      }}</text>
											<text class="pay_price" v-if="boxSource == 9">{{$t('¥')}}{{ activebox &&
        activebox.activity_info
        && activebox.activity_info.first_beishu }}</text>
											<text class="old_price">{{ boxPrice }}</text>
											<text class="old_price song-text" v-if="boxSource == 8">
												<br />
												({{ activebox && activebox.week_info && activebox.week_info.first_num
                        }}{{$t('抽起购')}})</text>
											<text class="old_price song-text" v-if="boxSource == 9">
												<br />
												({{ activebox && activebox.activity_info &&
        activebox.activity_info.first_num
                        }}{{$t('抽起购')}})</text>
										</view>

										<!-- 买N送N -->
										<view class="price"
											v-if="confrimView.type == 6 && (confrimView.source == 9 || confrimView.source == 8)">
											<text class="pay_price">{{$t('¥')}}{{ boxPrice }}</text>
											<text class="old_price song-text" v-if="boxSource == 8">
												({{$t('买')}}{{ activebox && activebox.week_info && activebox.week_info.buy_num
                        }}{{$t('送')}}{{ activebox && activebox.week_info && activebox.week_info.zsbuy_num
                        }})
											</text>
											<text class="old_price song-text" v-if="boxSource == 9">
												({{$t('买')}}{{ activebox && activebox.activity_info &&
        activebox.activity_info.buy_num }}{{$t('送')}}{{
        activebox &&
        activebox.activity_info
        && activebox.activity_info.zsbuy_num }})
											</text>
										</view>

										<!-- <view class="price" v-if="confrimView.type == 2 && boxSource == 8">
											<text class="pay_price">
												{{$t('¥')}}{{ Number(boxInfo.price).toFixed(2) }}
												<text style="margin-left: 10rpx;">({{ activebox.title }})</text>
											</text>
										</view> -->

										<view class="price" v-if="!confrimView.type && !confrimView.source">{{$t('¥')}}{{ boxPrice
                      }}</view>
										<view class="num" v-if="isActivityBox">x{{ confrimView.num }}</view>
										<view class="num" v-else>x{{ num }}</view>
									</view>
								</view>
							</view>
							<view class="amount">
								<view class="num_text">
									{{$t('数量')}}
								</view>
								<view class="right">
									<view class="num" v-if="isActivityBox">x{{ confrimView.num }}</view>
									<view class="num" v-else>x{{ num }}</view>
								</view>
							</view>
							<view v-if="usedCoupon.length != 0" @click="goSelect"
								class="rowitem n-flex-row n-justify-between" style="margin-top: 10rpx">
								<view class="l">
									<!-- <image src="../../static/image/quanlogo.png" mode=""></image> -->
									{{$t('优惠券')}}
								</view>
								<!--         <u-icon
                label-pos="left"
                :label-color="youhuiNum == '0' ? '#999' : '#d81e06'"
                color="#999"
                name="arrow-right"
                :label="youhuiNum == '0' ? '未选择优惠券' : '-{{$t('¥')}}' + youhuiNum"
                v-if="!isActivityBox"
              ></u-icon> -->
								<u-icon label-pos="left" :label-color="youhuiName ? '#d81e06' : '#999'" color="#999"
									name="arrow-right" :label="youhuiName ? youhuiName : $t('未选择优惠券')"></u-icon>
							</view>
							<!-- 星石抵扣 -->
							<view class="rowitem n-flex-row n-justify-between">
								<view class="l">
									<!-- <image src="../../static/image/y2.png" mode=""></image> -->
									{{$t('星石')}}
								</view>
								<view class="xs_dikou" v-if="newOffer_remarks.xingshi_dikou">
									{{ newOffer_remarks.xs }}{{$t('星石抵扣了')}}<text
										class="mony">{{ newOffer_remarks.xingshi_dikou }}</text>{{$t('元')}}
									<!-- {{ diKou == 0 ? '无可抵扣数量' : '使用' + (diKou * 100).toFixed(0) + '星石抵扣{{$t('¥')}}' + diKou }} -->
								</view>
							</view>
							<!-- <view view class="total" v-if="offer_remarks != ''" style="color: #999; font-size: 26rpx">
              优惠说明：
              <text style="font-size: 24rpx">{{ offer_remarks }}</text>
            </view> -->
							<!-- <view class="total" v-if="youhuiNum > 0">
							共计优惠：
							<text>{{$t('¥')}}{{ youhuiNum }}</text>
						</view> -->
							<!-- 连拍 -->
							<view class="amount" v-if="xianshilijian > 0">
								<view class="left">
									{{$t('连拍优惠')}}
								</view>
								<view class="lianpai">
									<text class="icon">{{$t('连')}}</text>
									<text class="money">-{{$t('¥')}}{{ xianshilijian }}</text>
								</view>
							</view>
							<view v-if="boxInfo.id">
								<view class="rowitem payrow xyb-cell" v-if="is_integral > 0 && boxInfo.id != 13">
									<!-- @click="luckyDeduction = true"> -->
									<view class="l">
										<!-- <image src="../../static/image/xr.png" mode=""></image> -->
										{{$t('幸运币抵扣')}}
									</view>
									<view class="payrow-right">
										<text v-if="isSelectXyb">-{{$t('¥')}}{{ interger_dikou }}</text>
										<!-- <u-icon name="arrow-right" color="#999"></u-icon> -->
									</view>
								</view>
							</view>
							<view class="amount">
								<view class="left bold">
									{{$t('合计')}}
								</view>
								<view class="right">
									<text class="icon">{{$t('¥')}}</text>
									<text class="money">{{ pay_price }}</text>
								</view>
							</view>
						</view>

						<view class="boxList-odds" v-show="isHw">
							<view class="boxList-odds-0">
								<view class="boxList-odds-left">
									<text>{{$t('获得')}}</text>
									<text>{{$t('概率')}}</text>
								</view>
								<view class="boxList-odds-right">
									<view class="boxList-odds-right-item" v-for="item in blind_box_odds" :key="item.id">
										<view class="t-i">{{ item.title }}{{$t('款')}}</view>
										<view class="b-i">{{ item.rate }}%</view>
									</view>
								</view>
							</view>
							<view class="boxList-odds-1">{{$t('因概率对小数点后三位进行四舍五入处理，故存在总值不为100%的可能')}}</view>
						</view>


						<view class="box1" style="margin-top: 20rpx">
							<u-radio-group style="display: block" width="34rpx" v-model="paymode"
								active-color="#70DDE0">
								<!-- #ifdef MP-WEIXIN -->
								<view class="rowitem payrow" @click="selectPay('wechat')">
									<view class="l">
										<image src="../../static/image/weixinf.png" mode=""></image>
										{{$t('微信')}}
									</view>
									<u-radio name="wechat"></u-radio>
								</view>
								<!-- #endif -->
								<!-- #ifdef APP-PLUS -->
								<view class="rowitem payrow" @click="selectPay('wechat')" v-if="app_wxpay_status == 1">
									<view class="l">
										<image src="../../static/image/weixinf.png" mode=""></image>
										{{$t('微信')}}
									</view>
									<u-radio name="wechat"></u-radio>
								</view>
<!-- 								<view class="rowitem payrow" @click="selectPay('alipay')" v-if="app_alipay_status == 1">
									<view class="l">
										<image src="../../static/image/zhifubao.png" mode=""></image>
										{{$t('支付宝')}}
									</view>
									<u-radio name="alipay"></u-radio>
								</view> -->
								<view class="rowitem payrow" @click="selectPay('usdt')" v-if="epay_usdt_status == 1">
									<view class="l">
										<image src="../../static/image/usdt.png" mode=""></image>
										{{$t('USDT')}}
									</view>
									<u-radio name="usdt"></u-radio>
								</view>
								<view class="rowitem payrow" @click="selectPay('paypal')" v-if="epay_paypal_status == 1">
									<view class="l">
										<image src="../../static/image/usdt.png" mode=""></image>
										{{$t('Paypal')}}
									</view>
									<u-radio name="paypal"></u-radio>
								</view>
								<!-- #endif -->

								<!-- #ifdef H5 -->
								<!--     <view class="rowitem payrow" @click="selectPay('wechat')" v-if="epay_wxpay_status == 1">
                  <view class="l">
                    <image src="../../static/image/weixinf.png" mode=""></image>
                    {{$t('微信')}}
                  </view>
                  <u-radio name="wechat"></u-radio>
                </view>
                <view class="rowitem payrow" @click="selectPay('alipay')" v-if="epay_alipay_status == 1">
                  <view class="l">
                    <image src="../../static/image/zhifubao.png" mode=""></image>
                    {{$t('支付宝')}}
                  </view>
                  <u-radio name="alipay"></u-radio>
                </view> -->

								<view class="rowitem payrow" @click="selectPay('usdt')" v-if="epay_usdt_status == 1">
									<view class="l">
										<image src="../../static/image/usdt.png" mode=""></image>
										{{$t('USDT')}}
									</view>
									<u-radio name="usdt"></u-radio>
								</view>
								<view class="rowitem payrow" @click="selectPay('paypal')" v-if="epay_paypal_status == 1">
									<view class="l">
										<image src="../../static/image/paypal.png" mode=""></image>
										{{$t('Paypal')}}
									</view>
									<u-radio name="paypal"></u-radio>
								</view>
								<!-- #endif -->

								<!--  <view class="rowitem payrow" @click="selectPay('integral')">
                <view class="l">
                  <image src="../../static/image/xr.png" mode=""></image>
                  幸运币(余额：{{ xyb || 0 }})
                </view>
                <u-radio name="integral"></u-radio>
              </view> -->
							</u-radio-group>
							<!-- <view v-if="boxInfo.id">
                <view class="rowitem payrow xyb-cell" v-if="is_integral > 0 && boxInfo.id != 13" @click="luckyDeduction = true">
                  <view class="l">
                    <image src="../../static/image/xr.png" mode=""></image>
                    幸运币抵扣
                  </view>
                  <view class="payrow-right">
                    <text v-if="isSelectXyb">-{{$t('¥')}}{{ interger_dikou }}</text>
                    <u-icon name="arrow-right" color="#999"></u-icon>
                  </view>
                </view>
              </view> -->
						</view>
						<scroll-view :scroll-top="0" scroll-y="true" class="scroll-rule-Y">
							<u-parse :html="deliveryRuleText"></u-parse>
						</scroll-view>
					</view>

					<view class="obtm">
						<button @click="submit" v-if="num == 1 && paymode != 'score'">
							{{$t('立即支付')}}
							<text>{{$t('¥')}}{{ pay_price }}</text>
						</button>
						<button @click="submit" v-if="num == 1 && paymode == 'score'">
							{{$t('立即支付')}}
							<text>{{$t('¥')}}{{ pay_price }}</text>
						</button>

						<button @click="
        submit();
      bf_anjianyin();
      " v-if="num != 1 && boxInfo.xryh == 1 && paymode != 'score'">
							{{$t('立即支付')}}
							<text>{{$t('¥')}}{{ pay_price }}</text>
						</button>
						<button @click="
        submit();
      bf_anjianyin();
      " v-if="num != 1 && boxInfo.xryh == 1 && paymode == 'score'">
							{{$t('立即支付')}}
							<text>{{$t('¥')}}{{ pay_price }}</text>
						</button>

						<button @click="
        submit();
      bf_anjianyin();
      " v-if="num != 1 && boxInfo.xryh != 1 && paymode != 'score'">
							{{$t('立即支付')}}
							<text>
								<text>{{$t('¥')}}{{ pay_price }}</text>
							</text>
						</button>
						<button @click="
        submit();
      bf_anjianyin();
      " v-if="num != 1 && boxInfo.xryh != 1 && paymode == 'score'">
							{{$t('立即支付')}}
							<text>{{$t('¥')}}{{ pay_price }}</text>
						</button>
					</view>
					<view class="xieyi" >
						<u-checkbox v-model="xieyi" shape="circle" active-color="#70DDE0" label-size="22" style="padding: 0 20rpxx;">
							{{$t('我已满18岁，已阅读并同意')}}
							<text @click.stop="$.to('/pages/my/agreement?type=pay_tipstips')">《{{$t('支付服务协议')}}》</text>
						</u-checkbox>
					</view>
				</view>

				<view class="syouhui" v-else>
					<view class="youtit">
						<view class="back" @click="selectCoupon = false">
							<u-icon size="40" name="arrow-left"></u-icon>
						</view>
						<view class="youhuit">{{$t('优惠详情')}} </view>
					</view>
					<view class="youhuicon">
						<scroll-view scroll-y class="shitu">
							<radio-group>
								<view class="couList" v-for="(item, idx) in usedCoupon" :key="idx"
									@click="selectCoupon1(item)">
									<view class="l">
										<view class="aa">
											<template v-if="item.type == 1">
												{{$t('¥')}}
												<text class="pri">{{ item.amount }}</text>
											</template>
											<template v-if="item.type == 2">
												<text class="pri">{{ item.discount }}{{$t('折')}}</text>
											</template>

											<!-- 	<view class="tiao" v-if="item.typetag == 0">无门槛</view>
										<view class="tiao" v-if="item.typetag == 1">满{{ item.mzamount }}减{{ item.amount }}</view> -->
										</view>
									</view>
									<view class="r">
										<view class="ll">
											<view class="t">{{ item.name }}</view>
											<!-- <view class="use">可用</view> -->
											<view class="qi" style="margin-top: 20rpx">
												{{$t('有效期至')}}
												{{ $u.timeFormat(item.end_time, 'yyyy-mm-dd hh:MM:ss') }}
											</view>
										</view>
										<view class="rr">
											<radio :value="item.id + ''" :checked="currentCoupon.id == item.id"
												color="#63D7D6" style="transform: scale(0.8)" />
										</view>
									</view>
								</view>
							</radio-group>
						</scroll-view>
						<view class="btn" @click="confirmCoupon">{{$t('确认')}}</view>
					</view>
				</view>
			</u-popup>

			<!-- <u-modal :show-cancel-button="true" @cancel="cancelLogin" @confirm="$.to('/pages/my/login')" v-model="isLogin"
			content="您还未登录,请先登录再进行操作"></u-modal> -->

			<!-- <view class="loadingContent" v-if="isLoading">
			<div id="preloader">
				<div class="te-loader">
				  <div class="te-blue">
				</div>
				</div>
			</div>
		</view> -->
			<!-- 白嫖展示baipiaoShow -->
			

			<!-- 中奖详情 -->
			<u-popup v-model="tongShow" mode="center" :custom-style="{ backgroundColor: 'rgba(0, 0, 0, 0)' }"
				:mask-custom-style="{ background: 'rgba(0, 0, 0, 0.9)' }">
				<view class="tongShowView">
					<view class="tongShowView-0">{{ tongObj.username }}</view>
					<view class="tongShowView-1">
						<u-divider bg-color="transparent" color="#f5ebc3"
							border-color="#f5ebc3">{{$t('获得')}}</u-divider>
					</view>
					<view class="tongShowView-2">
						<view class="tongShowView-2-img">
							<image :src="tongObj.goods_image" mode=""></image>
						</view>
						<view class="tongShowView-2-text">{{ tongObj.goods_name }}</view>
					</view>
					<view class="tongShowView-3" @click="tongShow = false">{{$t('我也要玩')}}</view>
				</view>
			</u-popup>

			<!-- 保底说明 -->
			<u-popup v-model="showBaodi" mode="bottom">
				<view class="baodi-view">
					<view class="baodi-view-0">
						<text>{{$t('规则说明')}}</text>
						<u-icon name="close" size="30rpx" @click="showBaodi = false"></u-icon>
					</view>
					<view class="baodi-view-1">{{ baodi_name }}</view>
					<view class="baodi-view-2">
						{{$t('该盒子每抽')}}{{ baodi_zcount }}{{$t('')}}次，{{ baodi_zcount }}{{$t('次内必出')}}<text>{{ baodi_level_name
              }}{{$t('款')}}</text>{{$t('或以上的物品。触发保底时，会将普通款物品升级为隐藏款，隐藏款物品的等级均为稀有款或以上')}}
					</view>
					<view class="baodi-view-1">{{$t('隐藏款物品')}}</view>
					<view class="baodi-view-2">{{$t('触发升级的隐藏款物品来源于盲盒商品池外，不影响开盒概率，物品等级最低为稀有款')}}</view>
					<view class="baodi-view-buttom" @click="showBaodi = false">{{$t('知道了')}}</view>

				</view>
			</u-popup>

			<!-- 是否使用幸运币抵扣-->
			<u-popup v-model="luckyDeduction" mode="bottom" :mask-close-able="false">
				<view class="xyb-popup">
					<view class="xyb-popup-title">
						{{$t('幸运币')}}<text>（{{$t('余额')}}{{ convertToNumber(xyb, 0) }})</text>
						<!-- <u-icon name="close"  class="xyb-close"></u-icon> -->
					</view>
					<view class="xyb-popup-cell" @click="changSelectXyb">
						<view class="xpc-left">{{$t('不使用幸运币')}}</view>
						<u-icon name="checkmark-circle-fill" color="#db904c" size="40rpx" v-if="!isSelectXyb"></u-icon>
						<view class="no-circle-fill" v-if="isSelectXyb"></view>
					</view>
					<view class="xyb-popup-cell" @click="changSelectXyb">
						<view class="xpc-left">{{$t('使用')}}{{ convertToNumber(interger_count, 0) }}{{$t('幸运币抵扣')}}<text>
								{{$t('¥')}}{{ interger_dikou }}</text>
						</view>
						<u-icon name="checkmark-circle-fill" color="#db904c" size="40rpx" v-if="isSelectXyb"></u-icon>
						<view class="no-circle-fill" v-if="!isSelectXyb"></view>
					</view>
					<view class="xyb-popup-submit" @click="handleXyb">
						{{$t('确认')}}
					</view>
				</view>
			</u-popup>

			<!-- 微信小程序支付弹窗 -->
			<u-popup v-model="mpWxPayModal" z-index="99999999999" mode="center"
				:mask-custom-style="{ background: 'rgba(0, 0, 0, 0.6)' }">
				<view class="mpWxPayPopup">
					<view class="bg">
						<img class="closeImg" src="https://sjmanghe.com/imageself/wx_xcx_modal_close.png"
							@click="mpWxPayClose" alt="img">
						<img class="qrImg" :show-menu-by-longpress="true" :src="WxOffImg" alt="">
						<img class="downImg" src="https://sjmanghe.com/imageself/wx_xcx_down_btn.png" @click="copyUrl"
							alt="img">
					</view>
				</view>
			</u-popup>
			<uni-popup ref="popupLimits" type="top" heigth="200" :is-mask-click="false" @maskClick="popupClcik">
				<view class="qweqwe">
					<view>{{$t('申请手机或耳机的麦克风权限')}}</view>
					<view>{{$t('申请相册权限')}}</view>
				</view>
			</uni-popup>
		</view>
	</view>
</template>

<script>
	import kefu from '@/components/kefu.vue';
	import {
		qy_appKey,
		app_type,
		hw_version,
		purchase_scheme,
		drawingRange,
	} from '@/utils/keyControl.js';
	// #ifdef APP-PLUS
	var qiyuModule = uni.requireNativePlugin('Netease-QiyuModule');
	// #endif
	export default {
		data() {
			return {
				showTitle: true,
				backgroundBar: 'transparent',
				isLoading: true,
				usedCoupon: [],
				currentCoupon: '', //当选择的优惠券
				Confirmed: '', //已确认的优惠券
				youhuiNum: '0',
				swiperCurrent: 0,
				goodsshow: false, //所有商品列表
				id: '', //盲盒id
				blind_box_odds: [], //盲盒商品概率
				boxList: [], //盲盒商品列表
				allBoxList: [],
				gunList: [], //底部滚动商品数据
				muteBgMusic: false,
				name: '', //盲盒名字
				totalGoods: [], //没循环的商品
				goodsPrice: '0.00', //商品价格
				boxPrice: '0.00', //盲盒价格
				boxInfo: '', //盲盒详情
				orderShow: false, //订单弹窗
				luckshow: false, //抽奖弹窗
				isShiwan: true, //是否试玩
				num: '', //几抽
				// #ifdef MP-WEIXIN
				xieyi: false,
				// #endif
				// #ifndef MP-WEIXIN
				xieyi: true,
				// #endif
				// #ifdef MP-WEIXIN
				paymode: 'usdt',
				// #endif

				// #ifdef H5
				paymode: 'usdt',
				// #endif

				// #ifdef APP-PLUS
				paymode: 'alipay',
				// #endif
				selectCoupon: false, //选择优惠券
				kfshow: false,
				max: '',
				min: '',
				bi: '',
				total: '',
				xyTotal: '',
				fGoods: {
					cs: [],
					ss: [],
					xy: [],
					gj: []
				},
				pay_price: 0, //支付价格
				buy_fangan: [], //购买方案
				currentCoupon_id: 0, //优惠券ID
				dian: 'dian1',
				xing: '', //星石
				diKou: 0, //抵扣星石数量
				statusBarHeight: 0,
				tongView: [], //需要展示的数据。
				tongList: [], //中奖通知
				tong: '',
				tnoTime: null,
				dings: '',
				integralPrice: 0,
				xyb: 0, //幸运币
				offer_remarks: '',
				userInfo: {},
				noClick: true,
				deliveryRuleText: '',
				deliveryRuleTextTitle: '',
				couponshow: false, //优惠券弹窗
				daojushow: false, //道具卡弹窗
				couponList: [], //优惠券列表,
				newCouponList: [],
				cardList: [], //道具卡
				cardShow: false,
				isCard: true, //我的道具卡与使用规则切换
				isLogin: false,
				page: 1,
				status: 'more', //  加载状态  more:有更多数据  noMore:已加载全部数据  loading:数据加载中
				StatusBar: null,
				CustomBar: null,
				StatusBarRpx: null,
				CustomBarRpx: null,
				boxSource: null, // 来源 5新人活动 6买1送1 7免单白嫖 // 今日限定暂定8
				baipiaoShow: false,
				isActivityBox: false, // 是否是活动盒子
				zid: null, // 限定id
				tongShow: false, // 查看中奖详情
				tongObj: {
					username: '',
					goods_image: '',
					goods_name: ''
				}, //中奖详情
				is_baodi: 0, // 1保底 0不是
				baodi_ucount: 0, // 用户保底已购买
				baodi_zcount: 0, // 总抽数
				baodi_name: '', // 名字
				baodi_level_name: '', // 等级名字
				confrimView: {
					blind_box_info: null,
					count: null,
					num: null,
					open: null,
					present_blindbox_id: null,
					present_buy_num_limit: null,
					price: null,
					type: null,
					week_info: null,
					source: null,
					activity_info: null,
				},
				youhuiName: null, // 优惠名字
				activebox: {},
				showBaodi: false, // 是否展示保底说明

				newOffer_remarks: {
					xs: null,
					xingshi_dikou: null
				}, // 星石说明
				xingshi_dikou: 0, // 可以抵扣的价格
				nes_xs: 0, //星石
				app_wxpay_status: null, //代表app微信支付开启，
				app_alipay_status: null, //代表app支付宝支付开启
				epay_alipay_status: null, //代表h5支付宝开启，
				epay_usdt_status: null,
				epay_wxpay_status: null, //代表h5微信支付开启
				epay_paypal_status: null,
				isOpenXyb: 0, // 今日消费达到一定 开启幸运币支付

				is_integral: 0, // 积分抵扣 1可以使用 1消费 0未消费
				interger_dikou: 0, // 抵扣的数量
				interger_count: 0, // 需要扣除的幸运币
				luckyDeduction: false, // 是否展示幸运币抵扣弹窗
				isSelectXyb: true, // 是否选中幸运币抵扣
				notUsedXyb: 0, // 未使用幸运币抵扣前的价格
				storageMrPayInfo: null, //  默认优惠详情
				isSHowBox: false,
				limitCount: 0,
				mpWxPayModal: false, //微信小程序支付弹窗
				WxOffImg: '', //微信公众号二维码
				appDownUrl: '', //微信小程序下载app地址
				isHw: false, //是否启用华为专用
				xianshilijian: null, //显示立减价格
				isRange: false, // 是否展示抽中范围
			    intervalId: null,   // 定时器 ID，用于停止定时器
			    timeout: 300000,    // 超时时间，单位：毫秒（这里设为 5 分钟）
			    startTime: 0,       // 记录开始时间
			    taskId: '12345',    // 任务 ID，假设是查询任务的标识符
			    status: null,       // 存储任务状态
			    isTimeout: false    // 标记是否超时
			};
		},
		async onLoad(option) {
			this.id = option.id;
			this.boxSource = option.boxSource;
			await this.getboxGoods(option.id)
			if (option.zid) {
				this.zid = option.zid;
			}
			/* 活动盒子 */
			if (option.boxSource) {
				this.isActivityBox = true;
				this.getActiveBoxInfo();
			} else {
				this.isActivityBox = false;
			}
			this.get_blind_box_odds();
			// this.getBox();
			this.muteBgMusic = uni.getStorageSync('muteBgMusic')
			uni.loadFontFace({
				family: 'myfont',
				source: 'url("http://m-admin.mhbox.top/YouSheBiaoTiHei.ttf")'
			});
			this.getTong();
			uni.$on('chongchou', (data) => {
				this.choujiang(true);
				let fangan = {};
				let fangan_index = 0;
				this.boxInfo.buy_data1.forEach(function(item, index) {
					if (item.number == data.num) {
						fangan = item;
						fangan_index = index;
					}
				});
				this.selectChou(fangan, fangan_index);
			});
			this.getHeight();
			this.getXing();
		},
		onPageScroll(e) {
			if (e.scrollTop >= 0) {
				let a = e.scrollTop / 200;
				this.backgroundBar = `rgba(255,255,255,${a})`;
				if (e.scrollTop >= 540) {
					this.showTitle = false;
				} else {
					this.showTitle = true;
				}
			} else {
				this.backgroundBar = 'transparent';
			}
			// let query = uni.createSelectorQuery().in(this);
			// query
			// 	.select('#demo')
			// 	.boundingClientRect((data) => {
			// 		console.log('元素距离顶部的距离' + data.top);
			// 		if (data.top < 2) {
			// 			this.showTitle = false;
			// 		} else {
			// 			this.showTitle = true;
			// 		}
			// 		// 这个
			// 	})
			// 	.exec();
		},
		onShow() {
			this.isHw = hw_version;
			this.isRange = drawingRange;
			this.handleChouShow();
			this.getGeneral();
			this.getUser();
			this.muteBgMusic = uni.getStorageSync('muteBgMusic')
			this.orderShow = false;
			this.getYouhui();
			this.page = 1;
			this.statusBarHeight =
				uni.getSystemInfoSync()['statusBarHeight'] === 20 ? 200 : uni.getSystemInfoSync()['statusBarHeight'] + 88 +
				44 + 134;
			this.getDeliveryRuleText();
			this.getBox();
			if (uni.getStorageSync('user')) {
				this.isLogin = false;
				this.lingquan();
			} else {
				this.isLogin = true;
			}
		},
		onHide() {
			clearInterval(this.tnoTime);
		},
		onReady() {
			if (this.boxSource == 7) {
				// #ifdef MP-WEIXIN
				this.baipiaoShow = true;
				setTimeout(() => {
					this.baipiaoShow = false;
				}, 8000);
				// #endif
				// #ifdef APP-PLUS || H5
				const platform = uni.getSystemInfoSync().platform
				if (platform === 'ios') {
					console.log('ios')
					this.baipiaoShow = true;
					setTimeout(() => {
						this.baipiaoShow = false;
					}, 10000);
				} else {
					console.log('android')
					this.baipiaoShow = true;
					setTimeout(() => {
						this.baipiaoShow = false;
					}, 13000);
				}
				// #endif

			}
		},
		onReachBottom(e) {
			// console.log('到底了~')
			// this.page += 1;
			this.getboxGoods(this.id)
			// this.lower();
		},
		onUnload() {
			uni.$off('chongchou');
		},
		components: {
			kefu
		},
		methods: {
			/* 用户展示显示连抽 用于商店审核 */
			handleChouShow() {
				this.$http({
					url: 'api/common/get_xiaofei_count',
					data: {
						uid: uni.getStorageSync('user').id || 0
					}
				}).then((res) => {
					if (res.data.code == 1) {
						// count限制多少可见 user_count消费多少  isconsumption 是否消费>=1
						const {
							isconsumption
						} = res.data.data;
						this.isSHowBox = JSON.parse(isconsumption);
					}
				});
			},

			/* 获取今日消费 */
			getUserMoney() {
				this.$http({
					url: 'api/member/get_day_money'
				}).then((res) => {
					const UserDayMoney = parseFloat(res.data.data.money);
					if (UserDayMoney >= 400) {
						this.isOpenXyb = true
					} else {
						this.isOpenXyb = false
					}
				});
			},
			getGeneral() {
				this.$http({
						url: 'api/common/get_general'
					})
					.then((res) => {
						if (res.data.code == 1) {
							console.log(res.data.data, 'res.data.datares.data.data')
							this.app_wxpay_status = res.data.data.app_wxpay_status; //代表app微信支付开启，
							this.app_alipay_status = res.data.data.app_alipay_status; //代表app支付宝支付开启
							this.epay_alipay_status = res.data.data.epay_alipay_status; //代表h5支付宝开启，
							this.epay_usdt_status = res.data.data.epay_usdt_status; //代表h5支付宝开启，
							this.epay_wxpay_status = res.data.data.epay_wxpay_status; //代表h5微信支付开启
							this.epay_paypal_status = res.data.data.epay_paypal_status; //代表h5paypal开启
						}
					})
					.catch((err) => {});
			},
			//获取ip
			getIp() {
				this.$http({
						url: "api/Ios/get_ip",
					})
					.then((res) => {
						if (res.data.code == 1) {
							//res.data.data.ip
							return res.data.data.clear;
						}
					})
					.catch((err) => {});
			},
			/* 初始化七鱼 */
			testSetUserInfo() {
				let userInfo = uni.getStorageSync('user');
				console.log(userInfo, 'userInfo');
				const {
					id,
					username,
					mobile,
					image,
					create_time,
					update_time
				} = userInfo;
				// 调用同步方法
				qiyuModule.initSdk({
					appKey: qy_appKey,
					appName: '七鱼客服uniapp',
					pkCerName: 'PushKit推送证书名；对应云信的pkCername'
				});
				qiyuModule.setUserInfo({
						userId: id || this.getIp(),
						data: JSON.stringify([{
								key: "real_name",
								value: username ? username : '',
							},
							{
								key: "mobile_phone",
								hidden: true,
								value: mobile ? mobile : '',
							},
							{
								key: "avatar",
								value: image ? image : '',
							},
							{
								index: 5,
								key: "reg_date",
								label: "注册日期",
								value: create_time ? create_time : '',
							},
							{
								index: 6,
								key: "last_login",
								label: "上次登录时间",
								value: update_time ? update_time : '',
							},
						])
					},
					(ret) => {
						if (ret.code == 200) {
							// modal.toast({
							// 	message: '成功',
							// 	duration: 1.5
							// });
						} else {
							// modal.toast({
							// 	message: '失败' + JSON.stringify(ret.errMsg),
							// 	duration: 1.5
							// });
						}

						console.log('js打印' + JSON.stringify(ret));
					}
				);
				qiyuModule.updateOptions({
						isPullMessageFromServer: false,
						uiCustomization: {
							hideLeftAvatar: false,
							isShowTitleAvatar: true,
							hideRightAvatar: false,
							inputTextColor: "#ff5500",
						},
					},
					(url) => {
						//点击url的回调
						plus.runtime.openWeb(url);
					}
				);
				qiyuModule.setFinishPageSwitch(true);
				qiyuModule.setPermissionCallback((retCallback) => {
					//麦克风
					let value1 = uni.getStorageSync("is_KEFU_RECORD_AUDIO");
					if (value1 != 1) {
						this.$refs.popupLimits.open();
					}
					plus.android.requestPermissions(
						[
							"android.permission.RECORD_AUDIO",
							"android.permission.MODIFY_AUDIO_SETTINGS",
						],
						function(e) {
							if (e.deniedAlways.length > 0) {
								//权限被永久拒绝
								// 弹出提示框解释为何需要权限，引导用户打开设置页面开启
								console.log("权限被永久拒绝" + e.deniedAlways.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_RECORD_AUDIO", 2);

							}
							if (e.deniedPresent.length > 0) {
								//权限被临时拒绝
								// 弹出提示框解释为何需要权限，可再次调用plus.android.requestPermissions申请权限
								console.log("权限被临时拒绝" + e.deniedPresent.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_RECORD_AUDIO", 0);

							}
							if (e.granted.length > 0) {
								//权限被允许
								console.log("权限被允许" + e.granted.toString());
								this.$refs.popupLimits.close()
								uni.setStorageSync("is_KEFU_RECORD_AUDIO", 1);
							}
						},
						function(e) {
							console.log("Request Permissions error:" + JSON.stringify(e));
							uni.showToast({
								title: "Request Permissions error:" + JSON.stringify(e),
							});
						}
					);
					//相机 相册
					let value2 = uni.getStorageSync("is_KEFU_CAMERA");
					if (value2 != 1) {
						this.$refs.popupLimits.open();
					}
					plus.android.requestPermissions(
						[
							"android.permission.CAMERA",
							"android.permission.READ_EXTERNAL_STORAGE",
						],
						function(e) {
							if (e.deniedAlways.length > 0) {
								//权限被永久拒绝
								// 弹出提示框解释为何需要权限，引导用户打开设置页面开启
								console.log("权限被永久拒绝" + e.deniedAlways.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_CAMERA", 2);

							}
							if (e.deniedPresent.length > 0) {
								//权限被临时拒绝
								// 弹出提示框解释为何需要权限，可再次调用plus.android.requestPermissions申请权限
								console.log("权限被临时拒绝" + e.deniedPresent.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_CAMERA", 0);

							}
							if (e.granted.length > 0) {
								//权限被允许
								console.log("权限被允许" + e.granted.toString());
								this.$refs.popupLimits.close()
								uni.setStorageSync("is_KEFU_CAMERA", 1);
							}
						},
						function(e) {
							console.log("Request Permissions error:" + JSON.stringify(e));
							uni.showToast({
								title: "Request Permissions error:" + JSON.stringify(e),
							});
						}
					);
					//文件存储
					let value3 = uni.getStorageSync("is_KEFU_FILE");
					if (value3 != 1) {
						this.$refs.popupLimits.open();
					}
					plus.android.requestPermissions(
						[
							"android.permission.MANAGE_EXTERNAL_STORAGE",
							"android.permission.WRITE_EXTERNAL_STORAGE",
						],
						function(e) {
							if (e.deniedAlways.length > 0) {
								//权限被永久拒绝
								// 弹出提示框解释为何需要权限，引导用户打开设置页面开启
								console.log("权限被永久拒绝" + e.deniedAlways.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_FILE", 2);

							}
							if (e.deniedPresent.length > 0) {
								//权限被临时拒绝
								// 弹出提示框解释为何需要权限，可再次调用plus.android.requestPermissions申请权限
								console.log("权限被临时拒绝" + e.deniedPresent.toString());
								this.$refs.popupLimits.close();
								uni.setStorageSync("is_KEFU_FILE", 0);

							}
							if (e.granted.length > 0) {
								//权限被允许
								console.log("权限被允许" + e.granted.toString());
								this.$refs.popupLimits.close()
								uni.setStorageSync("is_KEFU_FILE", 1);
							}
						},
						function(e) {
							console.log("Request Permissions error:" + JSON.stringify(e));
							uni.showToast({
								title: "Request Permissions error:" + JSON.stringify(e),
							});
						}
					);
				});
			},
			//企业微信客服
			wxKefu() {
				this.$http({
						url: "api/member/get_weixin_state",
						data: {},
					})
					.then((res) => {
						if (res.data.code == 1) {
							let obj = res.data.data;
							if (obj.weixin_kefu == 1) {
								uni.navigateTo({
									url: "/pagesA/pages/my/wecom",
								});
							} else {
								this.startQiyu();
							}
						} else {
							this.$tip.tip(res.data.msg);
						}
					})
					.catch((err) => {});
			},
			/* 客服调用 */
			startQiyu() {
				qiyuModule.openServiceActivity({
					title: '官方客服',
					source: {
						title: '官方客服'
					},
					openMode: 'push'
				});
			},
			popupClcik() {
				this.$refs.popupLimits.close();
				this.startQiyu();
			},

			/* 客服接入 */
			openServer() {
				// #ifdef H5
				// #endif
				// #ifdef MP-WEIXIN
				// #endif
				// #ifdef APP-PLUS
				// #endif
			},
			openTong(obj) {
				this.tongObj = obj;
				this.tongShow = true;
			},
			getHeight() {
				let _that = this;
				uni.getSystemInfo({
					success: function(e) {
						let StatusBar = 0,
							CustomBar = 0,
							CustomVal = 0,
							StatusBarRpx = 0,
							CustomBarRpx = 0,
							unitRatioVal = 0;
						// #ifndef MP
						StatusBar = e.statusBarHeight;
						if (e.platform == 'android') {
							CustomBar = e.statusBarHeight + 50;
						} else {
							CustomBar = e.statusBarHeight + 45;
						}
						// #endif
						// #ifdef MP-WEIXIN
						StatusBar = e.statusBarHeight;
						let custom = wx.getMenuButtonBoundingClientRect();
						CustomVal = custom;
						CustomBar = custom.bottom + custom.top - e.statusBarHeight;
						// #endif
						// #ifdef MP-ALIPAY
						StatusBar = e.statusBarHeight;
						CustomBar = e.statusBarHeight + e.titleBarHeight;
						// #endif
						let unitRatio = 750 / uni.getSystemInfoSync().windowWidth;
						StatusBarRpx = StatusBar * unitRatio;
						CustomBarRpx = CustomBar * unitRatio;
						unitRatioVal = unitRatio;
						_that.StatusBar = StatusBar; //状态栏高度(px)
						_that.CustomBar = CustomBar; //整个标题栏高度(px)
						_that.StatusBarRpx = StatusBarRpx; //状态栏高度(rpx)
						_that.CustomBarRpx = CustomBarRpx; //整个标题栏高度(rpx)
						console.log(_that.StatusBar, _that.CustomBar, _that.StatusBarRpx, _that.CustomBarRpx);
					}
				});
			},

			/* 前端价格计算 */
			getPayPrice(youhuije) {
				if (this.isActivityBox) {
				} else {
					const price = ((this.floatInt(this.boxInfo.price) * this.num) * 1000 - youhuije * 1000) / 1000;
					this.pay_price = price > 0 ? price : 0;
					this.getNotUsed()
					console.log(this.pay_price, ' this.pay_price this.pay_price')
				}

			},

			pageSelectChou(fangan, idx) {
				this.choujiang(true);
				this.buy_fangan = fangan;
				this.num = fangan.number;
				this.swiperCurrent = idx;
			},
			cancelLogin() {
				// uni.navigateBack()
				this.isLogin = false;
			},
			// 获取我的道具卡
			getCard() {
				this.$http({
						url: 'api/member/get_my_card'
					})
					.then((res) => {
						if (res.data.code == 1) {
							if (res.data.data.length == 0) {
								this.cardShow = true;
							} else {
								this.cardShow = false;
							}
							this.cardList = res.data.data;
						} else {
							this.cardShow = true;
						}
					})
					.catch((err) => {});
			},
			// 领取全部优惠券
			receive(atype) {
				this.$http({
						url: 'api/member/receive_coupon',
						data: {
							a_type: atype
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.$tip.tip(res.data.msg);
							this.couponshow = false;
						} else {
							this.$tip.tip(res.data.msg);
						}
					})
					.catch((err) => {});
				if (this.newCouponList.length > 0 && atype != 3) {
					this.$http({
							url: "api/member/receive_coupon",
							data: {
								a_type: 3,
							},
						})
						.then((res) => {
							if (res.data.code == 1) {
								this.$tip.tip(res.data.msg);
							} else {
								this.$tip.tip(res.data.msg);
							}
						})
						.catch((err) => {});
				}
				this.lingquan();
			},

			async lingquan() {
				await Promise.all([
				  this.getYouhui_new(),
				  this.getYouhui()
				]);
				const aggregatedData = [...this.couponList, ...this.newCouponList ];
				this.couponList = aggregatedData;
			},
			async getYouhui() {
				this.$http({
						url: 'api/common/get_coupon',
						data: {
							uid: uni.getStorageSync('user').id,
							a_type: 1
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.couponList = res.data.data;
						}
					})
					.catch((err) => {});
			},
			/* 新人优惠券 */
			async getYouhui_new() {
				if (uni.getStorageSync("user").is_new == 1) {
				    await this.$http({
				    		url: "api/common/get_coupon",
				    		data: {
				    			uid: uni.getStorageSync("user").id,
				    			a_type: 3,
				    		},
				    	})
				    	.then((res) => {
				    		if (res.data.code == 1) {
				    			if (res.data.data.length > 0) {
				    				this.newCouponList = res.data.data;
				    			}
				    		}
				    	})
				    	.catch((err) => {});
				}
			},
			getUser() {
				this.$http({
						url: 'api/member/get_user_info'
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.xyb = res.data.data.integral;
							this.integral = res.data.data.integral;
						    this.getUserMoney();
						    this.getCard();
						}
					})
					.catch((err) => {});
			},
			//获取盲盒概率
			get_blind_box_odds() {
				this.$http({
						url: 'api/common/get_blind_box_odds',
						data: {
							blind_box_id: this.id
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.blind_box_odds = res.data.data;
						}
					})
					.catch((err) => {});
			},
			getTong() {
				this.$http({
						url: "api/common/get_blind_box_open_log",
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.tongList = res.data.data;
							this.tongz();
						}
					})
					.catch((err) => {});
			},
			tongz() {
				if (this.tongList.length == 0) {
					return;
				}
				this.tongView = [];
				let arr = this.tongList.map((item) => {
					let obj = {};
					obj.text = `${this.$t('恭喜')} ${item.username} ${this.$t('获得')} ${item.goods_name}`;
					obj.level_name = item.level_name || "传说";
					obj.goods_image = item.goods_image;
					obj.bg =
						"https://img.alicdn.com/imgextra/i1/2215984279448/O1CN01KeUqPk2JfEvwQ6LPW_!!2215984279448.png";
					return obj;
				});
				//定时显示顶部信息
				let srcData = arr.map(item => item);

				let time = 2500;

				let blink = false;

				let ctrl = this.initTimer(time, () => {
					if (!srcData.length) {
						ctrl.stop();
					}
					if (blink) {
						blink = !blink
						this.tongView.shift();
					} else {
						blink = !blink
						let one = srcData.shift();
						this.tongView.push(one);
					}
				}, {
					autoStart: true,
					im: true
				})

				this.tongCtrl = ctrl;

			},
			initTimer(
				t,
				cb,
				opt = {
					autoStart: false,
					im: false,
				}
			) {
				let pauseFlag = true;
				if (opt.autoStart) {
					pauseFlag = false;
				}

				this.tnoTime = setInterval(() => {
					if (!pauseFlag) {
						cb();
					}
				}, t);
				// Ctrl
				return {
					pause: () => {
						pauseFlag = true;
					},
					start: () => {
						if (opt.im) {
							cb();
						}
						pauseFlag = false;
					},
					stop: () => {
						clearInterval(this.tnoTime);
					},
				};
			},
			// 获取星石
			getXing() {
				return false;
				this.$http({
						url: 'api/member/get_user_info'
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.userInfo = res.data.data;
							uni.setStorageSync('user', res.data.data);
							uni.$emit('updataUser');
							this.xing = res.data.data.integral2;
							if (this.xing == 0) {
								this.getNotUsed();
								this.pay_price = this.floatInt(this.boxInfo.price) * this.num
								// this.get_box_price();
								return;
							}
							var max = (this.boxPrice * this.num * 0.1).toFixed(3);
							if (this.xing / this.boxInfo.integral2_dikou_rmb > max) {
								this.diKou = max;
							} else {
								this.diKou = (this.xing / this.boxInfo.integral2_dikou_rmb).toFixed(3);
							}
							if (this.isActivityBox) {
								const price = this.floatInt(this.confrimView.price) - this.diKou;
								this.pay_price = price > 0 ? price : 0;
							} else {
								const price =  this.floatInt(this.boxInfo.price) * this.num - this.diKou;
								this.pay_price = price > 0 ? price : 0;
							}
							this.getNotUsed();
						}
					})
					.catch((err) => {});
			},
			// 定位锚点
			ding(val) {
				this.dian = 'dian' + val.id;
			},

			// 获取商品列表
			getFgoods() {
				this.$http({
						url: 'api/common/get_blind_box_odds_goods',
						data: {
							blind_box_id: this.id
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.fGoods = res.data.data;
						}
					})
					.catch((err) => {});
			},
			// 选择优惠券
			selectCoupon1(val) {
				if (this.currentCoupon == val) {
					this.currentCoupon = '';
					this.Confirmed = '';
					this.youhuiNum = 0;
					this.currentCoupon_id = 0;
					this.get_box_price();
					return;
				}
				this.currentCoupon = val;
			},
			/* 字符串转小数 */
			floatInt(string, decimalPlaces = 1) {
				// 去掉逗号
				string = string.replace(/,/g, '');
				// 将字符串转换为数值
				const number = parseFloat(string);
				// 将数值保留指定小数位数
				const fixedNumber = number.toFixed(decimalPlaces);
				// 返回保留指定小数位数后的数值
				return parseFloat(fixedNumber);
				// let f = parseFloat(val);
				// let result = f.toFixed(length);
				// return result;
			},
			convertToNumber(params, decimalPlaces) {
				let string = String(params);
				// 去掉逗号
				string = string.replace(/,/g, '');
				// 转换为浮点数
				let number = parseFloat(string);
				// 如果小数位数为0，则直接返回整数部分
				if (decimalPlaces === 0 || !Number.isFinite(number)) {
					return Math.trunc(number);
				}
				// 如果有指定保留的小数位数
				if (decimalPlaces) {
					// 使用toFixed()方法保留指定小数位数
					number = +number.toFixed(decimalPlaces);
				}
				// 转换为数字类型，去掉多余的0
				return number;
			},
			// 确认选择优惠券
			confirmCoupon() {
				this.luckyDeduction = false, // 是否展示幸运币抵扣弹窗
					this.isSelectXyb = true, // 是否选中幸运币抵扣

					this.selectCoupon = false;
				this.youhuiName = this.currentCoupon.name || '';
				if (this.youhuiName) {
					this.notUsedXyb = this.currentCoupon.price;
					this.pay_price = this.currentCoupon.price;
					this.interger_dikou = this.currentCoupon.interger_dikou;
					this.interger_count = this.currentCoupon.interger_count;
					this.is_integral = this.currentCoupon.is_interger;
					if (this.is_integral == 1 && this.boxInfo.id != 13) {
						this.pay_price = this.currentCoupon.price_1;
						this.interger_dikou = this.currentCoupon.interger_dikou;
						this.interger_count = this.currentCoupon.interger_count;
					}
				} else {
					const {
						price,
						price_1,
						interger_dikou,
						interger_count,
						is_interger
					} = this.storageMrPayInfo;
					this.notUsedXyb = price;
					this.pay_price = price > 0 ? price : 0;
					this.interger_dikou = interger_dikou;
					this.interger_count = interger_count;
					this.is_integral = is_interger;
					if (this.is_integral == 1) {
						this.pay_price = price_1 > 0 ? price_1 : 0;
						this.interger_dikou = interger_dikou;
						this.interger_count = interger_count;
					}
				}


				// if(list.length > 0){
				// this.notUsedXyb =  list[0].price;
				// this.pay_price =  list[0].price_1;
				// this.interger_dikou = list[0].interger_dikou;
				// this.interger_count =list[0].interger_count;
				// }else{
				//   this.interger_dikou = res.data.data.interger_dikou;
				//   this.interger_count = res.data.data.interger_count;
				//   this.notUsedXyb =  price;
				//   this.pay_price =  price_1;
				//   this.interger_dikou = res.data.data.interger_dikou;
				//   this.interger_count = res.data.data.interger_count;
				// }

				//  if(this.nes_xs > 0){
				//   // console.log(convertToNumber(this.pay_price)* 1000  ,'this.pay_pricethis.pay_price')
				//    this.pay_price =  (this.convertToNumber(this.pay_price)* 10000 - this.convertToNumber(this.xingshi_dikou)* 10000) / 10000
				//    console.log(this.convertToNumber(this.pay_price) ,this.convertToNumber(this.xingshi_dikou ) ,'convertToNumber(this.xingshi_dikou )convertToNumber(this.xingshi_dikou )' )
				//  }else{
				//   this.pay_price =   this.pay_price 
				//  }
				//  console.log( this.pay_price ,'1111111111')
				// /* 幸运币抵扣 */
				// if(this.currentCoupon.is_interger === 1){
				// 		this.interger_dikou =  this.currentCoupon.interger_dikou;
				// 		this.interger_count =  this.currentCoupon.interger_count;
				// 		this.notUsedXyb = this.pay_price;
				// 	    this.pay_price =  ((this.pay_price * 10000) - ( this.interger_dikou * 10000)) / 10000;
				// 	     this.isSelectXyb = true
				// }
				// // if(this.is_integral > 0){
				// // 	console.log( this.pay_price ,'222222222222222')
				// // 	  // 存储notUsedXyb 是因为选择优惠券时进行操作
				// // 	  this.notUsedXyb = this.pay_price;
				// // 	  this.pay_price =  ((this.pay_price * 1000) - ( this.interger_dikou * 1000)) / 1000;
				// // 	  this.isSelectXyb = true
				// // }

			},
			//获取支付价格
			get_box_price() {
				return false
				if (this.isActivityBox) {
					this.pay_price = this.confrimView.price;
					return false;
				}
				// console.log(this.boxData[this.swiperCurrent].id ,'this.boxData[this.swiperCurrent].id')
				this.$http({
						url: 'api/pay/get_box_price',
						data: {
							boxid: this.id,
							num: this.num,
							paymode: this.paymode,
							currentCoupon_id: this.currentCoupon.id
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							this.pay_price = res.data.data.price;
							this.offer_remarks = res.data.data.offer_remarks;
						} else {
							this.$tip.tip(this.$t('获取价格失败，请关闭重试'));
						}
					})
					.catch((err) => {});
			},
			goSelect() {
				this.selectCoupon = true;
				//      if (this.isActivityBox) {
				//        this.getActivetUsed();
				//      } else {
				// this.getActivetUsed();
				//        // this.getNotUsed();
				//      }
			},
			// 获取未使用优惠券
			// getNotUsed() {
			//   this.$http({
			//     url: 'api/member/get_my_coupon'
			//   })
			//     .then((res) => {
			//       if (res.data.code == 1) {
			//         this.usedCoupon = res.data.data;
			//       }
			//     })
			//     .catch((err) => {});
			// },
			hide() {
				this.kfshow = false;
			},
			// 联系客服
			lxkefu() {
				this.$refs.child.getKf();
				this.kfshow = true;
			},
			// 查询支付订单状态
			yanZheng(order_sn) {
				uni.showLoading({
					title: '支付状态查询中...',
					mask: true
				});
				let minute = setInterval(() => {
					this.$http({
						url: `api/pay/get_order_status`,
						data: {
							order_no: order_sn
						}
					}).then((res) => {
						/* 支付成功 */
						if (res.data.data.pay_status == 1) {
							uni.hideLoading();
							clearInterval(minute);
							setTimeout(() => {
								uni.navigateTo({
									url: '/pages/home/luckbox'
								});
								setTimeout(() => {
									uni.$emit('paydata', {
										ooid: order_sn,
										id: this.boxInfo.id
										// num: 1
									});
								}, 600);
							}, 700);
						}
					});
				}, 1000); //一秒执行一次
			},

			// 新的活动支付
			confrimBtn() {
				if (!this.xieyi) {
					return this.$tip.tip(this.$t('请阅读并同意协议'));
				}
				let isInterger = this.isSelectXyb ? 1 : 0;
				let userInfo = uni.getStorageSync('user');
				uni.showLoading({
					title: this.$t('正在请求支付')+'...',
					mask: true
				});

				const params = {
					blind_box_id: this.boxInfo.id,
					source: this.boxSource,
					uid: userInfo.id,
					zid: this.zid || '',
					paymode: this.paymode,
					is_interger: isInterger,
					couponid: this.currentCoupon.id,
					// #ifdef H5
					client: 0,
					// #endif
					// #ifdef MP-WEIXIN
					client: 1,
					// #endif
					// #ifdef APP-PLUS
					client: 2
					// #endif
				};
				console.log(params, 'params');
				// `/pagesA/pages/my/confirm?boxSource=${this.boxSource}&blind_box_id=${this.boxInfo.id}&zid=${this.zid}`
				this.$http({
					url: `api/pay/newer_pay`,
					data: params
				}).then((res) => {
					if (res.data.code === 1) {
						
						// #ifdef H5
						this.fun.go_h5pay(res.data.data);
						// #endif
						
						
						
						const {
							data,
							localorder_no,
							pay_type,
							result_code
						} = res.data.data
						console.log(pay_type)
						
					
						
						
						
						// 支付宝支付 pay_type 为9 第三方支付
						if (this.paymode === 'alipay' && pay_type === 9) {
							let qrCode = encodeURIComponent(data.qr_code);
							let link_url = `alipays://platformapi/startapp?saId=10000007&qrcode=${qrCode}`;
							let platform = uni.getSystemInfoSync().platform; //获取平台判断
							uni.hideLoading();
							if (platform == 'android') {
								// plus.runtime.openURL(link_url);
								uni.navigateTo({
									url: '/pages/tabBar/h5'
								})
								setTimeout(() => {
									uni.$emit('go_h5', {
										url: link_url
									})
								}, 600)
							} else if (platform == 'ios') {
								plus.runtime.launchApplication({
									action: link_url
								});
								this.yanZheng(res.data.data.localorder_no);
							}
						}
						if (this.paymode === 'alipay' && pay_type !== 9) {
							this.fun
								.go_appalipay(res.data.data.pay_data)
								.then((payres) => {
									this.$tip.tip(this.$t('支付成功'), 'success');
									setTimeout(() => {
										uni.navigateTo({
											url: '/pages/home/luckbox'
										});
										setTimeout(() => {
											uni.$emit('paydata', {
												ooid: res.data.data.order_no,
												id: this.boxInfo.id,
												num: this.num
											});
										}, 600);
									}, 700);
								})
								.catch((payerr) => {
									this.$tip.tip(this.$t('支付失败'));
								});
						}
						if (this.paymode === 'wechat') {
							console.log(res.data.data, '_____pay_data')
							this.fun
								.go_appwxpay(res.data.data.pay_data)
								.then((payres) => {
									this.$tip.tip(this.$t('支付成功'), 'success');
									setTimeout(() => {
										uni.navigateTo({
											url: '/pages/home/luckbox'
										});
										setTimeout(() => {
											uni.$emit('paydata', {
												ooid: res.data.data.order_no,
												id: this.boxInfo.id,
												num: this.num
											});
										}, 600);
									}, 700);
								})
								.catch((payerr) => {
									this.$tip.tip(this.$t('支付失败'));
								});
						}
					} else if (res.data.code === 8) {
						//0元免支付的
						//  if (this.paymode === 'integral') {
						// console.log(this ,'this.num')
						//    this.$tip.tip('支付成功', 'success' , this.num);
						//    setTimeout(() => {
						//      uni.navigateTo({
						//        url: '/pages/home/luckbox'
						//      });
						//      setTimeout(() => {
						//        uni.$emit('paydata', {
						//          ooid: res.data.data.ooid,
						//          id: this.boxInfo.id,
						//          num: this.num
						//        });
						//      }, 600);
						//    }, 700);
						//  }\
						this.$tip.tip(this.$t('支付成功'), 'success', this.num);
						setTimeout(() => {
							uni.navigateTo({
								url: '/pages/home/luckbox'
							});
							setTimeout(() => {
								uni.$emit('paydata', {
									ooid: res.data.data.ooid,
									id: this.boxInfo.id,
									num: this.num
								});
							}, 600);
						}, 700);
						this.orderShow = false;
						this.$tip.tip(this.$t('支付成功'), 'success');
						// this.go_luckbox(res.data.data);
					} else {
						this.$tip.tip(res.data.msg);
					}
				});
			},
			async submit() {
				if (!uni.getStorageSync("user")) {
				    uni.redirectTo({
				    	url:'../../pages/my/login'
				    })
				}
				if (!this.xieyi) {
					this.$tip.tip(this.$t('请阅读并同意协议'));
					return;
				}
				if (this.paymode == '') {
					this.$tip.tip(this.$t('请选择支付方式'));
					return;
				}

				if (this.paymode === 'integral' && this.integral < this.pay_price) {
					return this.$tip.tip(this.$t('您的幸运币不足'));
				}

				if (this.isActivityBox) {
					//#ifdef H5 || MP-WEIXIN
					let status = await this.mpWxPayFun()
					if (status == 2) {
						this.confrimBtn();
					}
					//#endif
					//#ifndef MP-WEIXIN
					this.confrimBtn();
					//#endif
					return false;
				}
				//#ifdef H5 || MP-WEIXIN
				//小程序微信支付弹窗
				if (this.paymode == 'wechat') {
					let status = await this.mpWxPayFun()
					if (status == 2) {
						this.pay();
					}
				}
				//#endif
				//#ifndef MP-WEIXIN
				this.pay();
				//#endif

			},
			//获取小程序是否弹窗支付
			mpWxPayFun() {
				// this.$http({
				// 	url: 'api/member/get_xn',
				// 	data: {
				// 		type: app_type || ""
				// 	}
				// }).then((res) => {
				// 	if (res.data.code == 1) {
				// 		let obj = res.data.data;
				// 		//xiao_status 1开启 2关闭
				// 		//lianjietiantian天天下载 lianjie 其他端
				// 		this.mpWxPayModal = obj.xiao_status == 1 ? true : false;
				// 		this.WxOffImg = obj.xiao_share_xiao_bg;
				// 		this.appDownUrl = obj.lianjie;
				// 		return obj.xiao_status
				// 	}
				// })
			},
			mpWxPayClose() {
				this.mpWxPayModal = false
			},
			// 复制链接
			copyUrl() {
				if (this.appDownUrl == "") {
					this.$tip.tip(this.$t("出错了，请稍后再试"));
					return;
				}
				let url = decodeURIComponent(this.appDownUrl);
				this.mpWxPayModal = false
				uni.setClipboardData({
					data: url,
					success: () => {},
				});
			},
			// 支付
			pay() {
				let price = this.pay_price;
				uni.showLoading({
					title: this.$t('正在请求支付')+'...',
					mask: true
				});
				let isInterger = this.isSelectXyb ? 1 : 0;
				// return false;
				this.$http({
						url: 'api/pay/go_pay',
						data: {
							boxid: this.id,
							num: this.num,
							paymode: this.paymode,
							currentCoupon_id: this.currentCoupon.id,
							is_interger: 0,
							price: price,
							xs: (this.diKou * this.boxInfo.integral2_dikou_rmb).toFixed(0),
							// price: 0.01,
							// #ifdef H5
							client: 0,
							// #endif

							// #ifdef MP-WEIXIN
							client: 1,
							// #endif

							// #ifdef APP-PLUS
							client: 2
							// #endif
						}
					})
					.then((res) => {
						uni.hideLoading();
						if (res.data.code == 1) {
							// #ifdef H5
							this.fun.go_h5pay(res.data.data.data);
							// #endif

							// #ifdef MP-WEIXIN
							this.fun
								.go_mpwxpay(res.data.data.data)
								.then((payres) => {
									this.$tip.tip(this.$t('支付成功'), 'success');
									setTimeout(() => {
										uni.navigateTo({
											url: '/pages/home/luckbox'
										});
										setTimeout(() => {
											uni.$emit('paydata', {
												ooid: res.data.data.data.order_no,
												id: this.boxInfo.id,
												num: this.num
											});
										}, 600);
									}, 700);
								})
								.catch((payerr) => {
									this.$tip.tip(this.$t('支付失败'));
								});
							// #endif

							// #ifdef APP-PLUS
							if (this.paymode == 'wechat') {
								console.log(res.data.data.data, '_____pay_data')
								this.fun
									.go_appwxpay(res.data.data.data.pay_data)
									.then((payres) => {
										this.$tip.tip(this.$t('支付成功'), 'success');
										setTimeout(() => {
											uni.navigateTo({
												url: '/pages/home/luckbox'
											});
											setTimeout(() => {
												uni.$emit('paydata', {
													ooid: res.data.data.data.order_no,
													id: this.boxInfo.id,
													num: this.num
												});
											}, 600);
										}, 700);
									})
									.catch((payerr) => {
										this.$tip.tip(this.$t('支付失败'));
									});
							} else {
								this.fun
									.go_appalipay(res.data.data.data.pay_data)
									.then((payres) => {
										this.$tip.tip(this.$t('支付成功'), 'success');
										setTimeout(() => {
											uni.navigateTo({
												url: '/pages/home/luckbox'
											});
											setTimeout(() => {
												uni.$emit('paydata', {
													ooid: res.data.data.data.order_no,
													id: this.boxInfo.id,
													num: this.num
												});
											}, 600);
										}, 700);
									})
									.catch((payerr) => {
										this.$tip.tip(this.$t('支付失败'));
									});
							}
							// #endif
							
						} else if (res.data.code == 8) {
							//0元免支付的
							// if (this.paymode === 'integral' || this.pay_price == 0) {
							//   this.$tip.tip('支付成功', 'success');
							//   setTimeout(() => {
							//     uni.navigateTo({
							//       url: '/pages/home/luckbox'
							//     });
							//     setTimeout(() => {
							//       uni.$emit('paydata', {
							//         ooid: res.data.data.ooid,
							//         id: this.boxInfo.id,
							//         num: this.num
							//       });
							//     }, 600);
							//   }, 700);
							// }
							this.$tip.tip(this.$t('支付成功'), 'success');
							setTimeout(() => {
								uni.navigateTo({
									url: '/pages/home/luckbox'
								});
								console.log(res, "支付返回值")
								setTimeout(() => {
									uni.$emit('paydata', {
										ooid: res.data.data.ooid,
										id: this.boxInfo.id,
										num: this.num
									});
								}, 600);
							}, 700);

							this.orderShow = false;
							this.$tip.tip(this.$t('支付成功'), 'success');
							// this.go_luckbox(res.data.data);
						} else {
							this.$tip.tip(res.data.msg);
						}
					})
					.catch((err) => {});
			},

			// 获取未使用优惠券
			getNotUsed() {
				this.luckyDeduction = false, // 是否展示幸运币抵扣弹窗
					this.isSelectXyb = true, // 是否选中幸运币抵扣
					this.newOffer_remarks.xs = ''; // 星石说明
				this.newOffer_remarks.xingshi_dikou = ''; // 星石说明
				this.xingshi_dikou = 0; // 可以抵扣的价格
				this.nes_xs = 0; //星石
				let noPrice = 0
				// const xingshidiKou = this.floatInt(this.diKou) || 0
				if (this.isActivityBox) {
					console.log(this.confrimView.price, 'this.confrimView.pricethis.confrimView.price')
					noPrice = this.confrimView.price;
				} else {
					// noPrice =  (this.boxPrice * this.num).toFixed(2) 
					noPrice = this.pay_price
				}
				// console.log(noPrice, xingshidiKou ,'pay_pricepay_price')
				// return false
				this.$http({
						url: 'api/member/find_coupon',
						data: {
							box_id: this.boxInfo.id,
							price: noPrice
						}
					})
					.then((res) => {
						console.log(res, '返回值');
						if (res.data.code == 1) {
							const {
								price,
								price_1,
								is_interger,
								list
							} = res.data.data
							this.usedCoupon = res.data.data.list;
							this.is_integral = res.data.data.is_interger; //  1 可以幸运币支付 0 不可以
							this.newOffer_remarks.xs = res.data.data.xs; // 星石说明
							this.newOffer_remarks.xingshi_dikou = res.data.data.xingshi_dikou; // 星石说明

							/* 默认值*/
							this.interger_dikou = res.data.data.interger_dikou;
							this.interger_count = res.data.data.interger_count;
							this.notUsedXyb = res.data.data.price;
							this.pay_price = res.data.data.price;
							this.is_integral = res.data.data.is_interger;
							if (this.is_integral == 1) {
								this.pay_price = res.data.data.price_1;
								this.interger_dikou = res.data.data.interger_dikou;
								this.interger_count = res.data.data.interger_count;
							}

							/* 用户存储默认信息，用于确认不使用优惠券用 */
							this.storageMrPayInfo = res.data.data;

							/* 有惠券去取惠券第一个 */
							if (list.length > 0) {
								this.currentCoupon = list[0];
								this.youhuiName = list[0].name || '';
								this.notUsedXyb = list[0].price;
								this.pay_price = list[0].price;
								this.is_integral = list[0].is_interger;
								if (this.is_integral == 1) {
									this.pay_price = list[0].price_1;
									this.interger_dikou = list[0].interger_dikou;
									this.interger_count = list[0].interger_count;
								}
							}

							// this.nes_xs = res.data.data.xs //星石
							// this.notUsedXyb = price;
							// this.pay_price = price
							// if(res.data.data.xs > 0){
							//  this.newOffer_remarks = res.data.data.offer_remarks ;// 星石说明
							//  this.xingshi_dikou =  res.data.data.xingshi_dikou ;// 可以抵扣的价格
							//  /* 普通盒子计算*/
							//  //1 有优惠券就用返回优惠券的价格-xingshi_dikou
							//  if(res.data.data.list.length > 0){
							//  //  const youAfterPriec = res.data.data.list[0].price;
							//  //  this.pay_price  = (youAfterPriec * 10000 -  this.xingshi_dikou * 10000) / 10000;
							//  //  console.log(this.pay_price ,'this.pay_price')
							//  //    // this.pay_price = this.floatInt(res.data.data.list[0].price ,1)  -  res.data.data.xingshi_dikou;
							// 	// // // this.pay_price = ((this.floatInt(res.data.data.list[0].price ,2) * 10000) -  (res.data.data.xingshi_dikou * 10000)) /  10000;
							// 	// // console.log((this.floatInt(res.data.data.list[0].price ,2)  ,res.data.data.xingshi_dikou * 10000), '——————this.pay_pricethis.pay_price')
							// 	this.currentCoupon = res.data.data.list[0];
							// 	this.youhuiName = res.data.data.list[0].name || '';
							// 	// // /* 抵扣信息  */
							// 	// if(this.currentCoupon.is_interger === 1){
							// 	// 	this.interger_dikou =  this.currentCoupon.interger_dikou;
							// 	// 	this.interger_count =  this.currentCoupon.interger_count;
							// 	// }
							//  }else{
							//   if(this.isActivityBox){
							// 	   // this.pay_price = this.confrimView.price  -  res.data.data.xingshi_dikou
							// 	   this.pay_price = (this.confrimView.price * 10000  -  res.data.data.xingshi_dikou * 10000 ) / 10000
							//   }else{
							// 	  this.pay_price = ((this.floatInt(this.boxInfo.price ,2) * this.num) * 1000   -  res.data.data.xingshi_dikou * 1000) / 1000
							//   }
							//  }
							// }else{
							//  if(res.data.data.list.length > 0){
							// console.log(res.data.data.list[0].price ,'res.data.data.list[0].pricres.data.data.list[0].pric')
							// this.pay_price = this.floatInt(res.data.data.list[0].price ,1);
							// this.currentCoupon = res.data.data.list[0];
							// this.youhuiName = res.data.data.list[0].name || '';
							//  }else{
							// if(this.isActivityBox){
							// 	 this.pay_price = this.confrimView.price 
							// }else{
							// 	this.pay_price = this.floatInt(this.boxInfo.price) * this.num
							// }
							//  }
							// }


							console.log(this.usedCoupon, 'this.usedCouponthis.usedCoupon')
						} else {
							this.show = true;
						}
					})
					.catch((err) => {});
			},

			bf_anjianyin() {
				return;
				anniumusic.stop();
				anniumusic.play();
			},
			async getDeliveryRuleText() {
				this.$http({
						url: 'api/common/get_agreement',
						data: {
							name: this.isHw ? 'delivery_rule_huawei' : 'delivery_rule'
						}
					})
					.then((res) => {
						console.log(res);
						if (res.data.code == 1) {
							this.deliveryRuleText = res.data.data.content;
							this.deliveryRuleTextTitle = res.data.data.title;
						} else {
							this.$tip.tip(res.data.msg);
						}
					})
					.catch((err) => {});
			},
			getOrderInfo() {
				let data = null;
				if (this.boxSource == 8) {
					const today = new Date().getDay(); // 获取今天是一周中的第几天（0-6）
					const index = (today + 8) % 7;
					let userInfo = uni.getStorageSync('user');
					data = {
						blind_box_id: this.id,
						source: this.boxSource,
						uid: userInfo.id,
						zid: this.zid
					};
				} else {
					data = {
						blind_box_id: this.id,
						source: this.boxSource
						//
					};
				}
				this.$http({
					url: 'api/common/get_blind_source_box_goods',
					data: data
				}).then((res) => {
					this.confrimView.blind_box_info = res.data.data.blind_box_info;
					this.confrimView.count = res.data.data.source_info.count;
					this.confrimView.num = res.data.data.source_info.num;
					this.confrimView.open = res.data.data.source_info.open;
					this.confrimView.present_blindbox_id = res.data.data.source_info.present_blindbox_id;
					this.confrimView.present_buy_num_limit = res.data.data.source_info.present_buy_num_limit;
					this.confrimView.price = res.data.data.source_info.price;
					this.confrimView.type = res.data.data.source_info.type; //一周限定盒子类型
					this.confrimView.source = res.data.data.source_info.source;
					this.confrimView.week_info = res.data.data.source_info.week_info;
					this.confrimView.activity_info = res.data.data.source_info.activity_info && res.data.data
						.source_info.activity_info;
				});
			},

			/* 立即开箱 */
			choujiang() {
				if (!uni.getStorageSync("user")) {
				    uni.redirectTo({
				    	url:'../../pages/my/login'
				    })
				}
				this.youhuiName = ''
				if (this.isActivityBox) {
					this.pay_price = this.confrimView.price;
					this.num = parseInt(this.confrimView.num);
					// this.getActivetUsed();
					// this.getXing()
					this.orderShow = true;
					// this.orderShow = true
					this.getNotUsed();
					// // this.getXing()
					// this.get_box_price();
					// console.log(1212);
					// uni.navigateTo({
					// 	url: `/pagesA/pages/my/confirm?boxSource=${this.boxSource}&blind_box_id=${this.boxInfo.id}&zid=${this.zid}`
					// });
				} else {
					this.youhuiNum = 0;
					this.luckshow = true;
					this.currentCoupon = '';
					this.isShiwan = false;
					// this.getXing()
				}
			},

			//前往查看道具卡规则
			go_prop_card_rule() {
				uni.navigateTo({
					url: '/pages/my/agreement?type=prop_card_rule'
				});
			},
			chou(num, youhuije) {
				this.xianshilijian = youhuije;
				if (this.isShiwan == false) {
					if (num == 1) {
						if (this.boxInfo.xryh == 1) {
							this.$tip.tip(this.$t('新人礼盒至少三抽~'));
							return;
						}
					}
					if (this.boxInfo.xryh == 1) {
						if (this.boxInfo.yh == 0) {
							this.$tip.tip(this.$t('该礼盒只能抽取一次'));
							return;
						}
					}
				}
				this.num = num;
				if (this.isShiwan == false) {
					this.getPayPrice(youhuije)
					// this.getXing()
					// this.get_box_price();
					// this.pay_price = this.floatInt(this.boxInfo.price) * num - this.diKou
					this.orderShow = true;
				} else {
					uni.navigateTo({
						url: '/pages/home/luckbox'
					});

					setTimeout(() => {
						uni.$emit('cdata', {
							id: this.id,
							num: num
						});
					}, 300);
				}
				this.luckshow = false;
			},
			// chou(fangan) {
			// 	this.buy_fangan = fangan;
			// 	this.num = fangan.number;
			// 	if (this.isShiwan == false) {
			// 		this.getXing();
			// 		this.orderShow = true;
			// 	} else {
			// 		uni.navigateTo({
			// 			url: '/pages/home/luckbox'
			// 		});
			// 		setTimeout(() => {
			// 			uni.$emit('cdata', {
			// 				id: this.id,
			// 				num: fangan.number,
			// 				btnTitle: fangan.title
			// 			});
			// 		}, 300);
			// 	}
			// 	this.luckshow = false;
			// },
			formatRichText(html) {
				let newContent = html.replace(/<img[^>]*>/gi, function(match, capture) {
					match = match.replace(/style="[^"]+"/gi, '').replace(/style='[^']+'/gi, '');
					match = match.replace(/width="[^"]+"/gi, '').replace(/width='[^']+'/gi, '');
					match = match.replace(/height="[^"]+"/gi, '').replace(/height='[^']+'/gi, '');
					return match;
				});
				newContent = newContent.replace(/style="[^"]+"/gi, function(match, capture) {
					match = match.replace(/width:[^;]+;/gi, 'width:100%;').replace(/width:[^;]+;/gi,
						'width:100%;');
					return match;
				});
				newContent = newContent.replace(/<br[^>]*\/>/gi, '');
				newContent = newContent.replace(/\<img/gi, '<img style="width:100%;height:auto;display:block;"');
				return newContent;
			},
			lower(e) {
				if (this.status != 'noMore') {
					this.getBox();
				}
			},
			// 获取盲盒商品信息
			async getboxGoods(id) {
				await this.$http({
					url: `api/common/optimize_get_blind_box_goods`,
					method: 'GET',
					data: {
						blind_box_id: id,
						page: this.page,
						limit: 10
					}
				}).then(res => {
					if (res.data.code == 1) {
						if (this.page == 1) this.boxList = [];
						// this.boxList = res.data.data.goods_list;
						if (res.data.data.goods_list.length <= 0) {
							this.status = 'noMore';
						} else {
							let curPageData = res.data.data.goods_list;
							this.boxList = this.boxList.concat(curPageData);
							this.status = 'more';
							this.page++;
						}
						//          if (this.page == 1) this.boxList = [];
						//          let curPageData = res.data.data.goods_list;
						//          this.boxList = this.boxList.concat(curPageData);
						// console.log(this.boxList.length , total,this.boxList.length < Number(total)  ,'huhuhuhu')
						//          if (this.boxList.length < +total) {
						//            this.status = 'more';
						//            this.page++;
						//          } else {
						//            this.status = 'noMore';
						//          }
					}
				}).catch((err) => {

				});
			},
			//盲盒商品
			async getBox() {
				// let url = this.isActivityBox ?
				uni.showLoading({
					title: this.$t("加载中"),
				});
				
				if(!this.boxList.length){
					// console.log("===============================================走起来了")
					await this.getboxGoods(this.id)
					// console.log(JSON.stringify(this.boxList),'======================================>boxList')
				}
				
				this.$http({
						url: 'api/common/get_blind_box_goods',
						data: {
							blind_box_id: this.id,
							uid: uni.getStorageSync('user').id || ''
						}
					})
					.then((res) => {
						if (res.data.code == 1) {
							uni.hideLoading();
							const {
								baodi,
								baodi_ucount,
								baodi_zcount,
								baodi_name,
								baodi_level_name
							} = res.data.data.blind_box_info;
							this.is_baodi = baodi;
							this.baodi_ucount = baodi_ucount;
							this.baodi_zcount = baodi_zcount;
							this.baodi_name = baodi_name;
							this.baodi_level_name = baodi_level_name;
							// this.boxList = res.data.data.goods_list
							let total = res.data.data.total; // 数据的长度
							//          if (this.page == 1) this.boxList = [];
							//          let curPageData = res.data.data.goods_list;
							//          this.boxList = this.boxList.concat(curPageData);
							// console.log(this.boxList.length , total,this.boxList.length < Number(total)  ,'huhuhuhu')
							//          if (this.boxList.length < +total) {
							//            this.status = 'more';
							//            this.page++;
							//          } else {
							//            this.status = 'noMore';
							//          }
							// this.boxList.unshift({
							// 	goods_title_text: res.data.data.blind_box_info.title,
							// 	goods_price: res.data.data.blind_box_info.price,
							// 	goods_image: res.data.data.blind_box_info.image
							// })
							// this.boxList.sort((a, b) => {
							//   return b.goods_price - a.goods_price;
							// });
							// this.boxList.sort((a, b) => {
							//   return b.odds_sort_text - a.odds_sort_text;
							// });
							this.name = this.boxList[this.swiperCurrent].goods_title_text;
							this.goodsPrice = this.boxList[this.swiperCurrent].goods_price;
							this.boxPrice = res.data.data.blind_box_info.price;
							this.boxInfo = res.data.data.blind_box_info;
							//购买方案控制
							if (purchase_scheme && !this.isSHowBox) {
								this.boxInfo.buy_data1 = res.data.data.blind_box_info.buy_data1.filter((item) => {
									return item.buy_price < 200
								})
							}
							this.max = res.data.data.goods_price_max;
							this.min = res.data.data.goods_price_min;
							this.total = res.data.data.total;
							this.allBoxList = res.data.data.goods_list;
							this.integralPrice = res.data.data.blind_box_info.integral_price;
							// this.xyTotal = res.data.data.xynum
							// 数据不够5自动添加
							var data = res.data.data.goods_list;
							this.totalGoods = data;
							this.gunList = res.data.data.goods_list.concat();
							this.gunList.shift();
							this.isLoading = false;
							if (this.gunList.length < 8) {
								for (var i = 0; i < 8; i++) {
									if (this.gunList.length >= 8) {
										return;
									}
									this.gunList = this.gunList.concat(data);
									console.log(this.gunList);
								}
							}
						}
					})
					.catch((err) => {});
			},

			// 获取活的的盲盒信息
			getActiveBoxInfo() {
				uni.showLoading({
					title: this.$t("加载中"),
				});
				this.$http({
					url: 'api/pay/order_details',
					data: {
						boxid: this.id,
						zid: this.zid,
						source: this.boxSource,
						type: 1
					}
				}).then((res) => {
					this.activebox = res.data.data
					this.getOrderInfo();
				});
			},
			// 页面改变
			changeIdx(idx) {
				this.swiperCurrent = idx.detail.current;
				this.name = this.boxList[this.swiperCurrent].goods_title_text;
				this.goodsPrice = this.boxList[this.swiperCurrent].goods_price;
			},
			back() {
				// uni.navigateBack();
				uni.switchTab({
					url:'/pages/tabBar/home'
				})
				// uni.$emit('music', this.muteBgMusic);
			},
			playMusic() {
				this.muteBgMusic = !this.muteBgMusic;
				uni.setStorageSync('muteBgMusic', this.muteBgMusic)
			},
			// 选择支付方式
			selectPay(mode) {
				this.paymode = mode;
				this.get_box_price();
			},
			selectChou(fangan, idx) {
				this.buy_fangan = fangan;
				this.num = fangan.number;
				this.swiperCurrent = idx;
				if (this.isShiwan == false) {
					this.getXing();
					// this.orderShow = true
				} else {
					// uni.navigateTo({
					// 	url: '/pages/home/luckbox'
					// })
					// setTimeout(() => {
					// 	uni.$emit('cdata', {
					// 		id: this.id,
					// 		num: fangan.number,
					// 		btnTitle : fangan.title
					// 	})
					// }, 300)
				}
				// this.luckshow = false
			},
			shiwan() {
				uni.navigateTo({
					url: '/pages/home/luckbox'
				});
				setTimeout(() => {
					uni.$emit('cdata', {
						id: this.id,
						num: 1,
						btnTitle: this.buy_fangan.title
					});
				}, 300);
			},
			selectRate(params) {
				const {
					id
				} = params;
				this.boxList = [];
				this.boxList = this.allBoxList.filter((item) => {
					if (item.odds_id === id || !item.odds_id) {
						return item;
					}
				});
			},
			showAll(idx, goodInfo) {
				if (goodInfo.goods_id) {
					uni.navigateTo({
						url: '/pages/mall/goodsInfoBox?id=' + goodInfo.goods_id
					});
				} else {
					this.boxList = this.allBoxList;
				}
			},
			/* 幸运币选择 */
			changSelectXyb() {
				this.isSelectXyb = !this.isSelectXyb;
			},
			handleXyb() {
				if (this.isSelectXyb) {
					const price = ((this.notUsedXyb * 10000) - (this.interger_dikou * 10000)) / 10000;
					this.pay_price = price > 0 ? price : 0;
					this.isSelectXyb = true;
				} else {
					this.pay_price = this.notUsedXyb;
					this.isSelectXyb = false;
				}
				this.luckyDeduction = false;
			}
		},
		watch: {
			muteBgMusic(newValue, oldValue) {
				if (newValue) {
					// 开启静音
					this.$music.playBgm({
						mute: true
					});
				} else {
					// 关闭 静音
					this.$music.playBgm({
						mute: false
					});
				}
			}
		}
	};
</script>

<style>
	page {
		background-color: #f6f7f9;
	}
</style>
<style lang="scss">
	.tongShowView {
		color: #fff;
		width: 500rpx;
		box-sizing: border-box;
		display: flex;
		flex-direction: column;
		align-items: center;
		overflow: hidden;
		box-sizing: border-box;

		&-0 {
			font-size: 28rpx;
			color: #f5ebc3;
		}

		&-1 {
			padding: 40rpx 0rpx 10rpx;
		}

		&-2 {
			// padding: 50rpx 20rpx;
			margin: 0 auto;
			border: none;
			// background-color: rgb(151, 95, 255);
			// box-shadow: 0px 200rpx 200rpx rgb(210, 187, 253) inset, 0rpx 5rpx 200rpx rgba(5, 5, 5, 0.212),
			//   0rpx -200rpx 200rpx rgb(124, 54, 255) inset;
			// border-radius: 10rpx;
			height: 760rpx;
			width: 460rpx;
			background-image: url('https://img.alicdn.com/imgextra/i1/2215984279448/O1CN01eAzQzP2JfEvqLEFqz_!!2215984279448.png');
			background-size: 100% 100%;
			overflow: hidden;
			position: relative;

			.tongShowView-2-img {
				position: absolute;
				left: 50%;
				margin-left: -120rpx;
				top: 300rpx;
				width: 240rpx;
				height: 240rpx;

				image {
					width: 100%;
					height: 100%;
				}
			}

			.tongShowView-2-text {
				position: absolute;
				bottom: 70rpx;
				left: 50%;
				margin-left: -170rpx;
				width: 340rpx;
				font-size: 26rpx;
				word-break: break-all;
				text-overflow: ellipsis;
				display: -webkit-box;
				-webkit-box-orient: vertical;
				-webkit-line-clamp: 2;
				overflow: hidden;
				margin-top: 16rpx;
			}
		}

		&-3 {
			width: 420rpx;
			height: 120rpx;
			background-image: url('https://img.alicdn.com/imgextra/i4/2215984279448/O1CN016z7lVj2JfEvuRzFje_!!2215984279448.png');
			background-size: 100% 100%;
			// background-color: #8342ff;
			display: flex;
			justify-content: center;
			align-items: center;
			font-size: 34rpx;
			color: #fff;
			margin-top: 30rpx;
			margin-left: 30rpx;
		}
	}

	.top-view {
		position: fixed;
		top: 0;
		left: 0;
		z-index: 99999999;
		width: 100%;

		.icon_setUp {
			height: 88rpx;
			display: flex;
			align-items: center;

			.nav-img-view {
				display: flex;
				width: 70vw;
				justify-content: flex-end;

				.nav-img {
					width: 100rpx;
					height: 100rpx;
					background-color: pink;
					margin-left: 20rpx;
				}
			}
		}

		.showTitle-view {
			display: flex;
			justify-content: space-between;
			padding: 0 30rpx;
			box-sizing: border-box;

			.showTitle-2 {
				width: 460rpx;
				height: 80rpx;
				line-height: 80rpx;
				overflow: hidden;
				display: -webkit-box;
				-webkit-box-orient: vertical;
				-webkit-line-clamp: 1;
				text-overflow: ellipsis;
				flex-shrink: 0;
				text-align: center;
				font-size: 28rpx;
				// font-weight: bold;
				color: #000;
			}

			.showTitle-2-mapwx {
				width: 420rpx;
			}

			image {
				width: 60rpx;
				height: 50rpx;
			}
		}

		.logoName {
			height: 70rpx;
			display: flex;
			justify-content: space-between;
			box-sizing: border-box;
			align-items: center;

			.logoName_right {
				image {
					width: 60rpx;
					height: 50rpx;
				}

				.kf-button {
					display: inline;
					background-color: transparent;
					border: none;
					margin: unset;
					padding: unset;
					border-color: transparent;
					font-size: 24rpx;
				}

				button::after {
					border: none;
				}
			}
		}
	}

	.banner {
		background-image: url('https://img.alicdn.com/imgextra/i1/2215984279448/O1CN015Y7IEM2JfEvD4aasv_!!2215984279448.png');
		background-size: 100% 100%;
		overflow: hidden;

		.banner-view {
			height: 800rpx;

			.banner-view-item {
				display: flex;
				flex-direction: column;
				align-items: center;
			}

			.b-i-img {
				width: 400rpx;
				height: 400rpx;
				flex-shrink: 0;
				margin-top: 60rpx;

				image {
					width: 100%;
					height: 100%;
				}
			}

			.b-i-role {
				margin-top: 16rpx;
				width: 200rpx;

				image {
					width: 100%;
					height: 100%;
				}
			}

			.b-i-title {
				font-size: 24rpx;
				width: 600rpx;
				text-align: center;
				margin-top: 16rpx;
			}

			.b-i-price {
				margin-top: 16rpx;
				font-size: 28rpx;
				font-weight: bold;
			}
		}
	}

	.boxList-title-0 {
		// background-color: #fff;
		height: 100rpx;
		width: 100%;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;

		.b-0-0 {
			font-size: 26rpx;
			font-weight: bold;
		}
	}

	.boxList-title-1 {
		background-image: url('https://img.alicdn.com/imgextra/i4/2215984279448/O1CN01KiMCtb2JfEw22TScW_!!2215984279448.png');
		background-size: 100% 100%;
		// background-color: rgba(0, 0, 0, 0.6);
		height: 80rpx;
		display: flex;
		justify-content: space-between;
		color: #fff;
		padding: 0 30rpx;
		align-items: center;
		width: 100%;

		.boxList-title-1-left {
			display: flex;
			padding-left: 100rpx;
		}

		.boxList-title-1-right {
			padding-right: 40rpx;
			font-size: 26rpx;
		}
	}

	.boxList {
		.boxList-title {
			text-align: center;

			.b-0-1 {
				font-size: 22rpx;
			}
		}

		.boxList-odds {
			background-color: #fff;
			margin: 0 auto;
			margin-top: 10rpx;
			width: 690rpx;
			padding: 20rpx;
			box-sizing: border-box;

			.boxList-odds-0 {
				display: flex;
				flex-shrink: 0;

				.boxList-odds-left {
					flex-shrink: 0;
					width: 120rpx;
					display: flex;
					flex-direction: column;
					align-items: center;
					justify-content: center;
					color: #000;
					font-weight: bold;
				}

				.boxList-odds-right {
					display: flex;
					width: 100%;
					column-gap: 8rpx;

					.boxList-odds-right-item {
						flex: 1;
						height: 100rpx;
						border: 1px solid #d35365;
						margin-right: 16rpx;
						display: flex;
						flex-direction: column;
						justify-content: space-between;
						color: #d35365;
						text-align: center;

						.t-i {
							display: flex;
							justify-content: center;
							align-items: center;
							height: 100%;
							font-weight: bold;
						}

						.b-i {
							background-color: #d35365;
							color: #fff;
							text-align: center;
							font-size: 20rpx;
							padding: 6rpx 0;
						}
					}

					.boxList-odds-right-item:nth-child(2) {
						border: 1px solid #ff7256;
						color: #ff7256;

						.b-i {
							background-color: #ff7256;
						}
					}

					.boxList-odds-right-item:nth-child(3) {
						border: 1px solid #ee9a49;
						color: #ee9a49;

						.b-i {
							background-color: #ee9a49;
						}
					}

					.boxList-odds-right-item:nth-child(4) {
						border: 1px solid #ff8c69;
						color: #ff8c69;

						.b-i {
							background-color: #ff8c69;
						}
					}

					.boxList-odds-right-item:nth-child(4) {
						border: 1px solid #ff8c69;
						color: #ff8c69;

						.b-i {
							background-color: #ff8c69;
						}
					}
				}
			}

			.boxList-odds-1 {
				font-size: 20rpx;
				color: #adadae;
				margin-top: 20rpx;
			}
		}
	}

	.mh-goods-list {
		width: 690rpx;
		// padding: 30rpx 20rpx 20rpx 20rpx;
		/* margin-top: 30rpx; */
		display: flex;
		flex-wrap: wrap;
		margin: 20rpx auto;
		justify-content: space-between;

		.mh-goods-list-item {
			flex-shrink: 0;
			position: relative;
			background-color: #fff;
			width: 330rpx;
			text-align: center;
			padding: 15rpx 6rpx;
			margin-bottom: 30rpx;
		}

		// .mh-goods-list-item:nth-child(3n) {
		// 	margin-right: 0;
		// }
		.mh-goods-img-view {
			height: 330rpx;
			width: 330rpx;
			display: flex;
			justify-content: center;
			align-items: center;
			flex-shrink: 0;

			image {
				width: 250rpx;
				height: 250rpx;
			}
		}

		.mh-goods-name {
			color: #2c2c2c;
			width: 100%;
			font-size: 26rpx;
			line-height: 30rpx;
			height: 60rpx;
			margin-top: 6rpx;
			display: -webkit-box;
			text-align: left;
			overflow: hidden;
			-webkit-box-orient: vertical;
			-webkit-line-clamp: 2;
			padding: 0 14rpx;
			box-sizing: border-box;
		}

		.mh-goods-price {
			font-size: 34rpx;
			font-weight: bold;
			margin-top: 10rpx;
			width: 100%;
			text-align: left;
			padding: 0 14rpx;
			color: #d35365;
			box-sizing: border-box;
		}

		.mh-goods-price text {
			color: #c1c1c1;
			font-size: 20rpx;
		}

		.mh-goods-range {
			width: 100%;
			margin-top: 10rpx;
			color: #c1c1c1;
			font-size: 20rpx;
			padding-left: 14rpx;
			box-sizing: border-box;
			text-align: left;
		}

		.mh-goods-rate {
			width: 120rpx;
			height: 50rpx;
			position: absolute;
			top: 2rpx;
			left: 2rpx;
			/* transform: rotate(-20deg);
			-webkit-animation: rotate(-20deg);
			-moz-animation: rotate(-20deg); */
			z-index: 9;
		}
	}

	.bottom-view {
		width: 690rpx;
		// background-color: #2c2c2c;
		background-image: url('https://img.alicdn.com/imgextra/i2/2215984279448/O1CN01hEWcii2JfEvQXWuTQ_!!2215984279448.png');
		font-family: YouSheBiaTiHei;
		color: #fff;
		text-align: center;
		line-height: 120rpx;
		height: 120rpx;
		position: fixed;
		bottom: 50rpx;
		left: 30rpx;
		background-size: 100% 100%;
		z-index: 9999;
		font-size: 34rpx;
	}

	.bottom-view-5 {
		background-image: url('https://img.alicdn.com/imgextra/i3/2215984279448/O1CN01CH02vr2JfEvxzc70D_!!2215984279448.png');
		height: 90rpx;
		line-height: 90rpx;
		font-size: 54rpx;
	}

	.bottom-view-1 {
		background-image: url('../../static/image/new/4-removebg-preview.png');
	}

	.bottom-view-2 {
		background-image: url('https://img.alicdn.com/imgextra/i1/2215984279448/O1CN01nRAv7i2JfEvoL0dkW_!!2215984279448.png');
	}

	.bottom-view-3 {
		background-image: url('https://img.alicdn.com/imgextra/i3/2215984279448/O1CN01RIpKpJ2JfEvsqjpRn_!!2215984279448.png');
		font-family: YouSheBiaTiHei;
		font-size: 50rpx;
		padding-top: 6px;
	}

	.bottom-view-2 {
		font-size: 50rpx;

		.bottom-view-2-0 {
			text {
				font-size: 36rpx;
				margin-left: 10rpx;
				font-family: 'YouSheBiaTiHei';
			}

			.yuan::before {
				// content: '฿';
				letter-spacing: -12rpx;
			}
		}

		.bottom-view-2-positon {
			width: 200rpx;
			height: 40rpx;
			position: absolute;
			font-size: 36rpx;
			right: 0rpx;
			// font-family: PingFangSC-Regular,PingFang SC;
			color: #ca4137;
			top: -34rpx;
		}
	}

	.bottom-view-4 {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		font-family: YouSheBiaTiHei;
		background-image: url('https://www.sjmanghe.com/imageself/click.png');
		background-size: 100% 100%;
		padding-top: 20rpx;
		height: 120rpx;

		.bottom-view-4-0 {
			font-size: 46rpx;
			height: 46rpx;
			line-height: 46rpx;
		}

		.bottom-view-4-1 {
			font-size: 34rpx;
			height: 30rpx;
			line-height: 28rpx;
			font-family: inherit;
			position: relative;
			bottom: -6rpx;

			.yuan::before {
				// content: '฿';
				letter-spacing: -12rpx;
			}

			.labei-text {
				font-size: 32rpx;
				text-decoration: line-through;
			}

			.label-chou {
				font-size: 32rpx;
				margin-left: 8rpx;
			}

		}

		.bottom-view-4-positon {
			width: 200rpx;
			height: 40rpx;
			font-family: 'YouSheBiaTiHei';
			white-space: nowrap;
			overflow: hidden;
			text-overflow: clip;
			line-height: normal !important;
			display: flex;
			align-items: center;
			position: absolute;
			font-size: 26rpx;
			right: 34rpx;
			top: 4rpx;
		}
	}




	.newPeopleBox {
		width: 750rpx;
	}

	.newPeopleBox,
	.box11 {
		.newmainBox {
			background: url('../../static/image/enimg/newpeople.png') no-repeat;
			width: 750rpx;
			height: 784rpx;
			background-size: 100%;
			padding-top: 200rpx;
		}

		.youhuilist {
			width: 550rpx;
			height: 566rpx;
			margin: 0 auto;
		}

		.newmainBox .youhuibox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/youhui.png') no-repeat;
			background-size: 550rpx 157rpx;
			width: 550rpx;
			height: 157rpx;
			margin: 20rpx auto;
			display: flex;
			justify-content: space-between;
		}

		.newmainBox .youhuibox .left {
			display: flex;
			align-items: center;
			color: #255470;
			padding-left: 20rpx;
		}

		.newmainBox .youhuibox .left .name {
			font-size: 34rpx;
			margin-bottom: 10rpx;
			color: #255470;
		}

		.newmainBox .youhuibox .left .price1 {
			color: #255470;
			font-size: 28rpx;
		}

		.newmainBox .youhuibox .left .price1 .pri {
			font-weight: 700;
			font-size: 36rpx;
			color: #255470;
			vertical-align: -6%;
			margin-right: 8rpx;
		}

		.newmainBox .youhuibox .right {
			width: 160rpx;
			height: 156rpx;
			flex-shrink: 0;
			display: flex;
			align-items: center;
			justify-content: center;
			text-align: center;
		}

		.newmainBox .youhuibox .right .ling {
			border-radius: 50rpx;
			width: 120rpx;
			border-radius: 10rpx;
			text-align: center;
			line-height: 45rpx;
		}

		.newmainBox .youhuibox .right .active {
			background-color: #60e0e1;
			color: #fff;
		}

		.newmainBox .youhuibox .right .yiling {
			background-color: #9d9d9d;
			color: #fff;
		}

		.newmainBox .youhuibox .right .price {
			font-size: 28rpx;
			color: #fff;
			margin-bottom: 10rpx;
			font-weight: 700;
		}

		.newmainBox .youhuibox .right .price text {
			font-size: 46rpx;
			color: #fff;
		}

		.btm-2 {
			width: 750rpx;
			position: relative;
			top: -60rpx;
		}

		.btm-2 .btmBg {
			width: 750rpx;
			position: absolute;
			top: 0;
			left: 0;
		}

		.btm-2 .btn1 {
			width: 750rpx;
			position: absolute;
			top: 80rpx;
			left: 0;
			text-align: center;
		}

		.btm-2 .btn1 image {
			width: 350rpx;
			display: inline-block;
		}

		.off {
			text-align: center;
			margin-top: 180rpx;
		}

		.off {
			text-align: center;
			margin-top: 40rpx;
		}

		.off image,
		.off image,
		.tanBox .off image {
			width: 70rpx;
			height: 70rpx;
			display: inline-block;
		}

		.daojubox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/qo.png') no-repeat;
			background-size: 100%;
			width: 650rpx;
			height: 980rpx;
			padding: 30rpx;
			padding-top: 60rpx;
			box-sizing: border-box;
		}

		.daojubox .top {
			display: flex;
			justify-content: space-between;
			align-items: center;
		}

		.daojubox .top image {
			width: 350rpx;
		}

		.daojubox .rulebox {
			color: #164367;
		}

		.daojubox .rulebox .wen {
			border-radius: 50%;
			color: #164367;
			border: 4rpx solid #164367;
			width: 40rpx;
			height: 40rpx;
			line-height: 36rpx;
			text-align: center;
			font-weight: bold;
			display: inline-block;
			margin-right: 10rpx;
		}

		.nodata {
			height: 680rpx;
			text-align: center;
			display: flex;
			justify-content: center;
			align-items: center;
		}

		.nodata image {
			width: 340rpx;
			height: 340rpx;
		}

		.nodata .tit {
			font-size: 34rpx;
			margin: 20rpx 0;
		}

		.nodata .fun {
			font-size: 28rpx;
			color: #999;
		}

		.cardList .list {
			background-color: #fff;
			margin-bottom: 20rpx;
			padding: 20rpx;
			box-sizing: border-box;
			width: 100%;
		}

		.cardList .list .goods .picbox {
			background-color: #f1f2f6;
			width: 150rpx;
			height: 150rpx;
			padding: 20rpx;
			box-sizing: border-box;
			flex-shrink: 0;
		}

		.cardList .list .goods .picbox image {
			width: 100%;
			height: 100%;
		}

		.cardList .textbox {
			margin-left: 20rpx;
			width: 100%;
		}

		.cardList .textbox .tit {
			font-size: 32rpx;
		}

		.cardList .textbox .two {
			font-size: 28rpx;
			margin-top: 10rpx;
		}

		.cardList .textbox .qi {
			color: #999;
			font-size: 24rpx;
			margin-top: 10rpx;
		}

		.cardList .list .tip1 {
			color: #999;
			font-size: 24rpx;
			margin-top: 10rpx;
			line-height: 1.3;
		}

		.explain .tit {
			background-image: linear-gradient(#afc5f3, #94a0e4);
			font-size: 32rpx;
			display: inline-block;
			font-weight: bold;
			padding: 6rpx 15rpx;
			color: #333;
			margin-top: 15rpx;
		}

		.explain .tit text {
			margin: 0 10rpx;
		}

		.explain .btm {
			/* background-color: #fff; */
			text-align: center;
			padding-top: 30rpx;
		}

		.explain .btm .btn2 {
			display: inline-block;
			background-color: #a5b0e1;
			padding: 25rpx 80rpx;
		}

		.explain .text {
			color: #999;
			font-size: 24rpx;
		}

		.vbox {
			background-color: #fff;
			width: 650rpx;
			padding: 10rpx;
			box-sizing: border-box;
		}

		.vbox .v {
			width: 100%;
		}

		.vbox .btm {
			padding: 20rpx 0;
		}

		.vbox .btm button {
			background-color: #2ceaff;
			width: 50%;
		}

		.orderbox {
			font-family: "Microsoft Yahei";
			background-color: #fff;
			z-index: 999;
		}

		.orderbox .tit {
			text-align: center;
			padding: 30rpx 0;
			font-size: 32rpx;
		}

		.orderbox .con {
			background-color: #f3f4f8;
			padding: 20rpx;
			box-sizing: border-box;
			min-height: 800rpx;
		}

		.orderbox .con .box1 {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.orderbox .goods image {
			width: 150rpx;
			height: 150rpx;
			flex-shrink: 0;
		}

		.orderbox .goods .info {
			padding-top: 10rpx;
			width: 90%;
			margin-left: 30rpx;
		}

		.orderbox .goods .info .t {
			font-size: 34rpx;
		}

		.orderbox .goods .info .two {
			display: flex;
			justify-content: space-between;
			margin-top: 20rpx;
		}

		.orderbox .goods .info .two .price {
			font-size: 30rpx;
			font-weight: bold;
		}

		.orderbox .goods .info .two .num {
			color: #999;
		}

		.orderbox .rowitem {
			padding: 20rpx 0;
		}

		.orderbox .rowitem image {
			width: 45rpx;
			height: 45rpx;
			margin-right: 10rpx;
		}

		.orderbox .rowitem .l {
			display: flex;
			align-items: center;
		}

		.orderbox .total {
			border-top: 1rpx solid #e5e5e5;
			text-align: right;
			font-weight: bold;
			padding: 30rpx 0 10rpx;
		}

		.orderbox .total text {
			color: #d81e06;
			font-size: 32rpx;
		}

		.orderbox .payrow {
			/* width: 670rpx; */
			display: flex;
			align-items: center;
			justify-content: space-between;
		}

		.orderbox .obtm {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.orderbox .obtm button {
			background-color: #70dde0;
		}

		.orderbox .obtm button text {
			font-weight: bold;
		}

		.orderbox .xieyi {
			width: 690rpx;
			margin: 0 auto;
			padding: 10rpx 0;
			padding-bottom: calc(constant(safe-area-inset-bottom));
			padding-bottom: calc(env(safe-area-inset-bottom));
		}

		.syouhui {
			background-color: #fff;
		}

		.youtit {
			padding: 20rpx 0;
			display: flex;
			position: relative;
		}

		.youtit .back {
			padding: 0 20rpx;
			position: absolute;
		}

		.youtit .youhuit {
			font-size: 34rpx;
			text-align: center;
			width: 100%;
		}

		.youhuicon {
			background-color: #f4f8fb;
			/* min-height: 900rpx; */
			padding: 20rpx;
			box-sizing: border-box;
		}

		.youhuicon .shitu {
			height: 670rpx;
		}

		.youhuicon .shitu .couList {
			display: flex;
			height: 160rpx;
			border-radius: 6rpx;
			overflow: hidden;
			margin-bottom: 20rpx;
		}

		.youhuicon .shitu .couList .l {
			flex-shrink: 0;
			width: 160rpx;
			height: 160rpx;
			background-color: #63d7d6;
			display: flex;
			justify-content: center;
			align-items: center;
		}

		.youhuicon .shitu .couList .l .aa {
			font-size: 30rpx;
			color: #fff;
		}

		.youhuicon .shitu .couList .l .pri {
			font-size: 46rpx;
			color: #fff;
		}

		.youhuicon .shitu .couList .l .tiao {
			color: #fff;
			text-align: center;
			font-size: 24rpx;
		}

		.youhuicon .shitu .couList .r {
			background-color: #fff;
			width: 100%;
			padding: 20rpx;
			height: 160rpx;
			box-sizing: border-box;
			display: flex;
			align-items: center;
			justify-content: space-between;
		}

		.youhuicon .shitu .couList .r .ll .t {
			font-size: 32rpx;
		}

		.youhuicon .shitu .couList .r .use {
			margin: 8rpx 0;
		}

		.youhuicon .shitu .couList .r .qi {
			font-size: 24rpx;
			color: #999;
		}

		.youhuicon .btn {
			width: 100%;
			text-align: center;
			color: #fff;
			line-height: 80rpx;
			background-color: #63d7d6;
			font-size: 32rpx;
			margin-top: 20rpx;
			border-radius: 6rpx;
		}

		.luckbox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/luckbg.png') no-repeat;
			background-size: 100%;
			border-radius: 24rpx;
			box-sizing: border-box;
			padding: 30rpx;
			width: 650rpx;
			background-color: #fff;
		}

		.luckbox .top {
			justify-content: space-between;
			display: flex;
			align-items: center;
		}

		.luckbox .titpic {
			width: 50%;
		}

		.luckbox .goodsPic {
			width: 45%;
			position: relative;
			/* top: -80rpx; */
		}

		.luckbox .option {
			padding: 20rpx 0;
		}

		.luckbox .option .row {
			display: flex;
			flex-wrap: wrap;
			justify-content: center;
		}

		.luckbox .option .row .chou {
			// background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rx.webp') no-repeat;
			background-size: 100%;
			width: 50%;
			display: flex;
			align-items: center;
			text-align: center;
			height: 124rpx;
			margin: 15rpx 0;
			position: relative;
		}

		.jian {
			position: absolute;
			background-color: #ffeae5;
			font-size: 22rpx;
			color: #e54e20;
			padding: 2rpx 20rpx;
			border: 1rpx solid #e6a793;
			border-top-right-radius: 40rpx;
			border-bottom-right-radius: 40rpx;
			top: -20rpx;
			left: 10rpx;
		}

		.yuanj {
			font-size: 24rpx;
			color: #077c8b;
			text-decoration: line-through;
			margin-left: 5rpx;
		}

		.luckbox .option .row .chou .b {
			width: 100%;
		}

		.luckbox .option .row .chou .tit {
			font-size: 32rpx;
			margin-bottom: 6rpx;
		}

		.luckbox .option .shi {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rw.webp');
			height: 124rpx;
			text-align: center;
			background-size: 100% 124rpx;
			display: flex;
			align-items: center;
			margin-top: 15rpx;
			position: relative;
		}

		.luckbox .option .shi .b {
			width: 100%;
		}

		.ouhuang {
			background: url('https://xgmh.hui-xiang.cn/assets/img/pk.png') no-repeat;
			background-size: 100%;
		}

		.ouhuang .scroll {
			height: 920rpx;
			margin-top: 80rpx;
		}

		.ouhuang .scroll .listbox {
			padding: 0 30rpx;
			box-sizing: border-box;
		}

		.ouhuang .scroll .listbox .list {
			margin-bottom: 20rpx;
		}

		.ouhuang .scroll .listbox .picbox {
			position: relative;
		}

		.ouhuang .scroll .listbox .picbox image {
			width: 100%;
			height: 350rpx;
		}

		.ouhuang .scroll .listbox .picbox .text {
			padding: 0 20rpx;
			line-height: 80rpx;
			background-color: rgba(255, 255, 255, 0.8);
			position: absolute;
			left: 0;
			bottom: 0;
			width: 100%;
		}

		.tanBox {
			width: 600rpx;
			text-align: center;
		}

		.tanBox .pic image {
			width: 100%;
		}
	}

	.orderbox-top {
		background-color: transparent;

		.luckbox-top {
			background: transparent;
		}

		.luckbox .option .row .chou {
			margin: 0 10rpx;
			width: 200rpx;
			height: 90rpx;
			// background: linear-gradient(180deg, #eae8f8, #bbb4e4);
			background-color: rgba(91, 70, 198, 0.8);
			border: none;
			color: #fff;
		}
	}

	.loadingContent {
		height: 100vh;
		width: 100vw;
		// background-color: #5b46c6;
	}

	#preloader {
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		z-index: 999999999999;
		background: transparent;
		display: flex;
		justify-content: center;
		align-items: center;
	}

	.te-loader {
		position: relative;
		display: flex;
		align-items: center;
		justify-content: center;
		height: 300px;
		width: 300px;
		border-radius: 50%;
		box-shadow: inset -10px -10px 15px rgba(255, 255, 255, 1), inset 10px 10px 10px rgba(0, 0, 0, 0.1);
	}

	.te-loader::before {
		content: '';
		position: absolute;
		height: 200px;
		width: 200px;
		border-radius: 50%;
		box-shadow: -10px -10px 15px rgba(255, 255, 255, 1), 10px 10px 10px rgba(0, 0, 0, 0.1);
	}

	.te-blue {
		height: 186px;
		width: 220px;
		position: absolute;
		animation: rotate 5s linear infinite;
	}

	@keyframes rotate {
		100% {
			transform: rotate(360deg);
		}
	}

	.te-blue::before {
		content: '';
		position: absolute;
		height: 30px;
		border-radius: 50%;
		width: 30px;
		background: linear-gradient(45deg, #336dff, #5c89ff);
		box-shadow: 0 5px 10px rgb(0, 0, 0);
	}

	.luckbox {
		background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/luckbg.png') no-repeat;
		background-size: 100%;
		border-radius: 24rpx;
		box-sizing: border-box;
		padding: 30rpx;
		width: 650rpx;
		background-color: #fff;

		.top {
			justify-content: space-between;
			display: flex;
			align-items: center;
		}

		.titpic {
			width: 50%;
		}

		.goodsPic {
			width: 45%;
			position: relative;
			/* top: -80rpx; */
		}

		.option {
			padding: 20rpx 0;
		}

		.option .row {
			display: flex;
			justify-content: space-between;
		}

		.option .row .chou {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rx.webp') no-repeat;
			background-size: 100% 100%;
			width: 50%;
			display: flex;
			align-items: center;
			text-align: center;
			height: 168rpx;
			margin: 15rpx 0;
			position: relative;
			padding: 0 10rpx;
			box-sizing: border-box;
		}

		.jian {
			position: absolute;
			background-color: #ffeae5;
			font-size: 22rpx;
			color: #e54e20;
			padding: 2rpx 20rpx;
			border: 1rpx solid #e6a793;
			border-top-right-radius: 40rpx;
			border-bottom-right-radius: 40rpx;
			top: -20rpx;
			left: 10rpx;
		}

		.yuanj {
			font-size: 24rpx;
			color: #077c8b;
			text-decoration: line-through;
			margin-left: 5rpx;
		}

		.b {
			width: 100%;
		}

		.tit {
			font-size: 32rpx;
			margin-bottom: 6rpx;
		}

		.shi {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rw.webp');
			height: 124rpx;
			text-align: center;
			background-size: 100% 124rpx;
			display: flex;
			align-items: center;
			margin-top: 15rpx;
			position: relative;
		}

		.option .shi .b {
			width: 100%;
		}
	}

	.orderbox {
		font-family: "Microsoft Yahei";
		background-color: #fff;

		.tit {
			text-align: center;
			padding: 30rpx 0;
			font-size: 32rpx;
		}

		.con {
			background-color: #f3f4f8;
			padding: 20rpx;
			box-sizing: border-box;
			// min-height: 800rpx;
		}

		.con .box1 {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.amount {
			font-family: "Microsoft Yahei";
			background-color: #fff;
			margin: 0 auto;
			width: 100%;
			padding: 20rpx 0;
			box-sizing: border-box;
			display: flex;
			justify-content: space-between;

			.left {
				font-weight: 500;
			}

			.bold {
				font-weight: bold;
			}

			.right {
				.icon {
					font-size: 26rpx;
				}

				.money {
					font-weight: bold;
					font-size: 30rpx;
				}
			}

			.lianpai {
				font-size: 26rpx;

				.icon {
					color: #fff;
					padding: 5rpx 10rpx;
					background-color: #d81e06;
					margin-right: 10rpx;
				}

				.money {
					color: #d81e06;
				}
			}
		}

		.boxList-odds {
			background-color: #fff;
			margin: 0 auto;
			margin-top: 10rpx;
			width: 100%;
			padding: 20rpx;
			box-sizing: border-box;

			.boxList-odds-0 {
				display: flex;
				flex-shrink: 0;

				.boxList-odds-left {
					flex-shrink: 0;
					width: 120rpx;
					display: flex;
					flex-direction: column;
					align-items: center;
					justify-content: center;
					color: #000;
					font-weight: bold;
				}

				.boxList-odds-right {
					display: flex;
					width: 100%;
					column-gap: 8rpx;

					.boxList-odds-right-item {
						flex: 1;
						height: 100rpx;
						border: 1px solid #d35365;
						margin-right: 16rpx;
						display: flex;
						flex-direction: column;
						justify-content: space-between;
						color: #d35365;
						text-align: center;

						.t-i {
							display: flex;
							justify-content: center;
							align-items: center;
							height: 100%;
							font-weight: bold;
						}

						.b-i {
							background-color: #d35365;
							color: #fff;
							text-align: center;
							font-size: 20rpx;
							padding: 6rpx 0;
						}
					}

					.boxList-odds-right-item:nth-child(2) {
						border: 1px solid #ff7256;
						color: #ff7256;

						.b-i {
							background-color: #ff7256;
						}
					}

					.boxList-odds-right-item:nth-child(3) {
						border: 1px solid #ee9a49;
						color: #ee9a49;

						.b-i {
							background-color: #ee9a49;
						}
					}

					.boxList-odds-right-item:nth-child(4) {
						border: 1px solid #ff8c69;
						color: #ff8c69;

						.b-i {
							background-color: #ff8c69;
						}
					}

					.boxList-odds-right-item:nth-child(4) {
						border: 1px solid #ff8c69;
						color: #ff8c69;

						.b-i {
							background-color: #ff8c69;
						}
					}
				}
			}

			.boxList-odds-1 {
				font-size: 20rpx;
				color: #adadae;
				margin-top: 20rpx;
			}
		}

		.goods image {
			width: 150rpx;
			height: 150rpx;
			flex-shrink: 0;
		}

		.goods .info {
			padding-top: 10rpx;
			width: 90%;
			margin-left: 30rpx;
		}

		.goods .info .t {
			font-size: 34rpx;
		}

		.goods .info .two {
			display: flex;
			justify-content: space-between;
			margin-top: 20rpx;
		}

		.goods .info .two .price .pay_price {
			font-size: 30rpx;
			font-weight: bold;
		}

		.goods .info .two .price .old_price {
			font-size: 26rpx;
			text-decoration: line-through;
			margin-left: 20rpx;
			color: #666;
		}

		.song-text {
			text-decoration: none !important;
			color: #da3e06 !important;
			margin-left: 2rpx !important;
		}


		// .goods .info .two .num {
		//   color: #999;
		// }

		.rowitem {
			padding: 20rpx 0;
		}

		.rowitem image {
			width: 45rpx;
			height: 45rpx;
			margin-right: 10rpx;
		}

		.rowitem .l {
			display: flex;
			align-items: center;
		}

		.rowitem {
			.xs_dikou {
				.mony {
					color: #d81e06;
				}
			}
		}

		.total {
			border-top: 1rpx solid #e5e5e5;
			text-align: right;
			font-weight: bold;
			padding: 30rpx 0 10rpx;
		}

		.total text {
			color: #d81e06;
			font-size: 32rpx;
		}

		.payrow {
			/* width: 670rpx; */
			display: flex;
			align-items: center;
			justify-content: space-between;
		}

		.obtm {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.obtm button {
			background-color: #70dde0;
		}

		.obtm button text {
			font-weight: bold;
		}

		.xieyi {
			text-align: center;
			padding-bottom: 20rpx;
		}
	}

	.flxd-img {
		width: 100rpx;
		height: 100rpx;
		background-color: red;
		position: fixed;
		z-index: 99;
	}

	.flxd-img-0 {
		top: 250rpx;
	}

	.flxd-img-1 {
		top: 400rpx;
	}

	.flxd-img-2 {
		top: 550rpx;
	}

	.flxd-img-3 {
		right: 0rpx;
		top: 250rpx;
	}

	.baipiaoShow {
		display: flex;
		justify-content: center;
		align-items: center;
		color: #ea8126;
		flex-direction: column;
		height: 100vh;

		image {
			width: 100%;
			height: 100%;
		}
	}

	@keyframes zoom {
		from {
			transform: scale(0.4);
		}

		to {
			transform: scale(1.2);
		}
	}

	.syouhui {
		background-color: #fff;
	}

	.youtit {
		padding: 20rpx 0;
		display: flex;
		position: relative;
	}

	.youtit .back {
		padding: 0 20rpx;
		position: absolute;
	}

	.youtit .youhuit {
		font-size: 34rpx;
		text-align: center;
		width: 100%;
	}

	.youhuicon {
		background-color: #f4f8fb;
		/* min-height: 900rpx; */
		padding: 20rpx;
		box-sizing: border-box;
	}

	.youhuicon .shitu {
		height: 670rpx;
	}

	.youhuicon .shitu .couList {
		display: flex;
		height: 160rpx;
		border-radius: 6rpx;
		overflow: hidden;
		margin-bottom: 20rpx;
	}

	.youhuicon .shitu .couList .l {
		flex-shrink: 0;
		width: 160rpx;
		height: 160rpx;
		background-color: #63d7d6;
		display: flex;
		justify-content: center;
		align-items: center;
	}

	.youhuicon .shitu .couList .l .aa {
		font-size: 30rpx;
		color: #fff;
	}

	.youhuicon .shitu .couList .l .pri {
		font-size: 46rpx;
		color: #fff;
	}

	.youhuicon .shitu .couList .l .tiao {
		color: #fff;
		text-align: center;
		font-size: 24rpx;
	}

	.youhuicon .shitu .couList .r {
		background-color: #fff;
		width: 100%;
		padding: 20rpx;
		height: 160rpx;
		box-sizing: border-box;
		display: flex;
		align-items: center;
		justify-content: space-between;
	}

	.youhuicon .shitu .couList .r .ll .t {
		font-size: 32rpx;
	}

	.youhuicon .shitu .couList .r .use {
		margin: 8rpx 0;
	}

	.youhuicon .shitu .couList .r .qi {
		font-size: 24rpx;
		color: #999;
	}

	.youhuicon .btn {
		width: 100%;
		text-align: center;
		color: #fff;
		line-height: 80rpx;
		background-color: #63d7d6;
		font-size: 32rpx;
		margin-top: 20rpx;
		border-radius: 6rpx;
	}

	.scroll-rule-Y {
		height: 230rpx;
		width: 690rpx;
		margin: 10rpx auto 0;
		font-size: 22rpx;
		font-family: "Microsoft Yahei";
	}

	.kfclass {
		font-size: 24rpx !important;
		font-weight: 400;
	}

	.free {
		position: fixed;
		left: 6rpx;
		top: 600rpx;
		width: 110rpx;
		height: 100rpx;
		z-index: 8;
	}

	.dot-red {
		background-color: #fa3534;
		display: inline-block;
		height: 36rpx;
		width: 36rpx;
		line-height: 36rpx;
		border-radius: 18rpx;
		// overflow: hidden;
		text-align: center;
		color: #fff;
		font-size: 22rpx;
		position: absolute;
		top: -4rpx;
		right: 6rpx;
	}

	.free0 {
		top: 350rpx;

		image {
			width: 80rpx;
			height: 80rpx;
		}
	}

	.free1 {
		top: 490rpx;

		image {
			width: 80rpx;
			height: 80rpx;
		}
	}

	.free2 {
		top: 620rpx;

		image {
			width: 80rpx;
			height: 80rpx;
		}
	}

	.off {
		text-align: center;
		margin-top: 140rpx;
	}

	.newPeopleBox,
	.box11 {
		.newmainBox {
			background: url('../../static/image/enimg/newpeople.png') no-repeat;
			width: 750rpx;
			height: 784rpx;
			background-size: 100%;
			padding-top: 200rpx;
		}

		.youhuilist {
			width: 550rpx;
			height: 566rpx;
			margin: 0 auto;
		}

		.newmainBox .youhuibox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/youhui.png') no-repeat;
			background-size: 550rpx 157rpx;
			width: 550rpx;
			height: 157rpx;
			margin: 20rpx auto;
			display: flex;
			justify-content: space-between;
		}

		.newmainBox .youhuibox .left {
			display: flex;
			align-items: center;
			color: #255470;
			padding-left: 20rpx;
		}

		.newmainBox .youhuibox .left .name {
			font-size: 34rpx;
			margin-bottom: 10rpx;
			color: #255470;
		}

		.newmainBox .youhuibox .left .price1 {
			color: #255470;
			font-size: 28rpx;
		}

		.newmainBox .youhuibox .left .price1 .pri {
			font-weight: 700;
			font-size: 36rpx;
			color: #255470;
			vertical-align: -6%;
			margin-right: 8rpx;
		}

		.newmainBox .youhuibox .right {
			width: 160rpx;
			height: 156rpx;
			flex-shrink: 0;
			display: flex;
			align-items: center;
			justify-content: center;
			text-align: center;
		}

		.newmainBox .youhuibox .right .ling {
			border-radius: 50rpx;
			width: 120rpx;
			border-radius: 10rpx;
			text-align: center;
			line-height: 45rpx;
		}

		.newmainBox .youhuibox .right .active {
			background-color: #60e0e1;
			color: #fff;
		}

		.newmainBox .youhuibox .right .yiling {
			background-color: #9d9d9d;
			color: #fff;
		}

		.newmainBox .youhuibox .right .price {
			font-size: 28rpx;
			color: #fff;
			margin-bottom: 10rpx;
			font-weight: 700;
		}

		.newmainBox .youhuibox .right .price text {
			font-size: 46rpx;
			color: #fff;
		}

		.btm-2 {
			width: 750rpx;
			position: relative;
			top: -60rpx;
		}

		.btm-2 .btmBg {
			width: 750rpx;
			position: absolute;
			top: 0;
			left: 0;
		}

		.btm-2 .btn1 {
			width: 750rpx;
			position: absolute;
			top: 80rpx;
			left: 0;
			text-align: center;
		}

		.btm-2 .btn1 image {
			width: 350rpx;
			display: inline-block;
		}

		.off {
			text-align: center;
			margin-top: 180rpx;
		}

		.off {
			text-align: center;
			margin-top: 140rpx;
		}

		.off image,
		.off image,
		.tanBox .off image {
			width: 70rpx;
			height: 70rpx;
			display: inline-block;
		}

		.daojubox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/qo.png') no-repeat;
			background-size: 100%;
			width: 650rpx;
			height: 980rpx;
			padding: 30rpx;
			padding-top: 60rpx;
			box-sizing: border-box;
		}

		.daojubox .top {
			display: flex;
			justify-content: space-between;
			align-items: center;
		}

		.daojubox .top image {
			width: 350rpx;
		}

		.daojubox .rulebox {
			color: #164367;
		}

		.daojubox .rulebox .wen {
			border-radius: 50%;
			color: #164367;
			border: 4rpx solid #164367;
			width: 40rpx;
			height: 40rpx;
			line-height: 36rpx;
			text-align: center;
			font-weight: bold;
			display: inline-block;
			margin-right: 10rpx;
		}

		.nodata {
			height: 680rpx;
			text-align: center;
			display: flex;
			justify-content: center;
			align-items: center;
		}

		.nodata image {
			width: 340rpx;
			height: 340rpx;
		}

		.nodata .tit {
			font-size: 34rpx;
			margin: 20rpx 0;
		}

		.nodata .fun {
			font-size: 28rpx;
			color: #999;
		}

		.cardList .list {
			background-color: #fff;
			margin-bottom: 20rpx;
			padding: 20rpx;
			box-sizing: border-box;
			width: 100%;
		}

		.cardList .list .goods .picbox {
			background-color: #f1f2f6;
			width: 150rpx;
			height: 150rpx;
			padding: 20rpx;
			box-sizing: border-box;
			flex-shrink: 0;
		}

		.cardList .list .goods .picbox image {
			width: 100%;
			height: 100%;
		}

		.cardList .textbox {
			margin-left: 20rpx;
			width: 100%;
		}

		.cardList .textbox .tit {
			font-size: 32rpx;
		}

		.cardList .textbox .two {
			font-size: 28rpx;
			margin-top: 10rpx;
		}

		.cardList .textbox .qi {
			color: #999;
			font-size: 24rpx;
			margin-top: 10rpx;
		}

		.cardList .list .tip1 {
			color: #999;
			font-size: 24rpx;
			margin-top: 10rpx;
			line-height: 1.3;
		}

		.explain .tit {
			background-image: linear-gradient(#afc5f3, #94a0e4);
			font-size: 32rpx;
			display: inline-block;
			font-weight: bold;
			padding: 6rpx 15rpx;
			color: #333;
			margin-top: 15rpx;
		}

		.explain .tit text {
			margin: 0 10rpx;
		}

		.explain .btm {
			/* background-color: #fff; */
			text-align: center;
			padding-top: 30rpx;
		}

		.explain .btm .btn2 {
			display: inline-block;
			background-color: #a5b0e1;
			padding: 25rpx 80rpx;
		}

		.explain .text {
			color: #999;
			font-size: 24rpx;
		}

		.vbox {
			background-color: #fff;
			width: 650rpx;
			padding: 10rpx;
			box-sizing: border-box;
		}

		.vbox .v {
			width: 100%;
		}

		.vbox .btm {
			padding: 20rpx 0;
		}

		.vbox .btm button {
			background-color: #2ceaff;
			width: 50%;
		}

		.orderbox {
			background-color: #fff;
			z-index: 999;
		}

		.orderbox .tit {
			text-align: center;
			padding: 30rpx 0;
			font-size: 32rpx;
		}

		.orderbox .con {
			background-color: #f3f4f8;
			padding: 20rpx;
			box-sizing: border-box;
			min-height: 800rpx;
		}

		.orderbox .con .box1 {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.orderbox .goods image {
			width: 150rpx;
			height: 150rpx;
			flex-shrink: 0;
		}

		.orderbox .goods .info {
			padding-top: 10rpx;
			width: 90%;
			margin-left: 30rpx;
		}

		.orderbox .goods .info .t {
			font-size: 34rpx;
		}

		.orderbox .goods .info .two {
			display: flex;
			justify-content: space-between;
			margin-top: 20rpx;
		}

		.orderbox .goods .info .two .price {
			font-size: 30rpx;
			font-weight: bold;
		}

		.orderbox .goods .info .two .num {
			color: #999;
		}

		.orderbox .rowitem {
			padding: 20rpx 0;
		}

		.orderbox .rowitem image {
			width: 45rpx;
			height: 45rpx;
			margin-right: 10rpx;
		}

		.orderbox .rowitem .l {
			display: flex;
			align-items: center;
		}

		.orderbox .total {
			border-top: 1rpx solid #e5e5e5;
			text-align: right;
			font-weight: bold;
			padding: 30rpx 0 10rpx;
		}

		.orderbox .total text {
			color: #d81e06;
			font-size: 32rpx;
		}

		.orderbox .payrow {
			/* width: 670rpx; */
			display: flex;
			align-items: center;
			justify-content: space-between;
		}

		.orderbox .obtm {
			padding: 20rpx;
			box-sizing: border-box;
			background-color: #fff;
		}

		.orderbox .obtm button {
			background-color: #70dde0;
		}

		.orderbox .obtm button text {
			font-weight: bold;
		}

		.orderbox .xieyi {
			width: 690rpx;
			margin: 0 auto;
			padding: 10rpx 0;
			padding-bottom: calc(constant(safe-area-inset-bottom));
			padding-bottom: calc(env(safe-area-inset-bottom));
		}

		.syouhui {
			background-color: #fff;
		}

		.youtit {
			padding: 20rpx 0;
			display: flex;
			position: relative;
		}

		.youtit .back {
			padding: 0 20rpx;
			position: absolute;
		}

		.youtit .youhuit {
			font-size: 34rpx;
			text-align: center;
			width: 100%;
		}

		.youhuicon {
			background-color: #f4f8fb;
			/* min-height: 900rpx; */
			padding: 20rpx;
			box-sizing: border-box;
		}

		.youhuicon .shitu {
			height: 670rpx;
		}

		.youhuicon .shitu .couList {
			display: flex;
			height: 160rpx;
			border-radius: 6rpx;
			overflow: hidden;
			margin-bottom: 20rpx;
		}

		.youhuicon .shitu .couList .l {
			flex-shrink: 0;
			width: 160rpx;
			height: 160rpx;
			background-color: #63d7d6;
			display: flex;
			justify-content: center;
			align-items: center;
		}

		.youhuicon .shitu .couList .l .aa {
			font-size: 30rpx;
			color: #fff;
		}

		.youhuicon .shitu .couList .l .pri {
			font-size: 46rpx;
			color: #fff;
		}

		.youhuicon .shitu .couList .l .tiao {
			color: #fff;
			text-align: center;
			font-size: 24rpx;
		}

		.youhuicon .shitu .couList .r {
			background-color: #fff;
			width: 100%;
			padding: 20rpx;
			height: 160rpx;
			box-sizing: border-box;
			display: flex;
			align-items: center;
			justify-content: space-between;
		}

		.youhuicon .shitu .couList .r .ll .t {
			font-size: 32rpx;
		}

		.youhuicon .shitu .couList .r .use {
			margin: 8rpx 0;
		}

		.youhuicon .shitu .couList .r .qi {
			font-size: 24rpx;
			color: #999;
		}

		.youhuicon .btn {
			width: 100%;
			text-align: center;
			color: #fff;
			line-height: 80rpx;
			background-color: #63d7d6;
			font-size: 32rpx;
			margin-top: 20rpx;
			border-radius: 6rpx;
		}

		.luckbox {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/luckbg.png') no-repeat;
			background-size: 100%;
			border-radius: 24rpx;
			box-sizing: border-box;
			padding: 30rpx;
			width: 650rpx;
			background-color: #fff;
		}

		.luckbox .top {
			justify-content: space-between;
			display: flex;
			align-items: center;
		}

		.luckbox .titpic {
			width: 50%;
		}

		.luckbox .goodsPic {
			width: 45%;
			position: relative;
			/* top: -80rpx; */
		}

		.luckbox .option {
			padding: 20rpx 0;
		}

		.luckbox .option .row {
			display: flex;
			flex-wrap: wrap;
			justify-content: center;
		}

		.luckbox .option .row .chou {
			// background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rx.webp') no-repeat;
			background-size: 100%;
			width: 50%;
			display: flex;
			align-items: center;
			text-align: center;
			height: 124rpx;
			margin: 15rpx 0;
			position: relative;
		}

		.jian {
			position: absolute;
			background-color: #ffeae5;
			font-size: 22rpx;
			color: #e54e20;
			padding: 2rpx 20rpx;
			border: 1rpx solid #e6a793;
			border-top-right-radius: 40rpx;
			border-bottom-right-radius: 40rpx;
			top: -20rpx;
			left: 10rpx;
		}

		.yuanj {
			font-size: 24rpx;
			color: #077c8b;
			text-decoration: line-through;
			margin-left: 5rpx;
		}

		.luckbox .option .row .chou .b {
			width: 100%;
		}

		.luckbox .option .row .chou .tit {
			font-size: 32rpx;
			margin-bottom: 6rpx;
		}

		.luckbox .option .shi {
			background: url('https://v3mh6.oss-cn-beijing.aliyuncs.com/51api/rw.webp');
			height: 124rpx;
			text-align: center;
			background-size: 100% 124rpx;
			display: flex;
			align-items: center;
			margin-top: 15rpx;
			position: relative;
		}

		.luckbox .option .shi .b {
			width: 100%;
		}

		.ouhuang {
			background: url('https://xgmh.hui-xiang.cn/assets/img/pk.png') no-repeat;
			background-size: 100%;
		}

		.ouhuang .scroll {
			height: 920rpx;
			margin-top: 80rpx;
		}

		.ouhuang .scroll .listbox {
			padding: 0 30rpx;
			box-sizing: border-box;
		}

		.ouhuang .scroll .listbox .list {
			margin-bottom: 20rpx;
		}

		.ouhuang .scroll .listbox .picbox {
			position: relative;
		}

		.ouhuang .scroll .listbox .picbox image {
			width: 100%;
			height: 350rpx;
		}

		.ouhuang .scroll .listbox .picbox .text {
			padding: 0 20rpx;
			line-height: 80rpx;
			background-color: rgba(255, 255, 255, 0.8);
			position: absolute;
			left: 0;
			bottom: 0;
			width: 100%;
		}



		.tanBox {
			width: 600rpx;
			text-align: center;
		}

		.tanBox .pic image {
			width: 100%;
		}
	}

	.invite {
		position: fixed;
		right: 6rpx;
		top: 620rpx;
		width: 80rpx;
		height: 80rpx;
		z-index: 8;
	}

	.playBtn {
		width: 80rpx;
		height: 80rpx;
		position: fixed;
		right: 6rpx;
		top: 360rpx;
		z-index: 8;
	}

	.music {
		width: 100rpx;
		height: 100rpx;
		position: fixed;
		right: -10rpx;
		top: 470rpx;
		z-index: 8;
		animation: music 4s linear 0s infinite normal none;
	}

	.stop {
		animation-play-state: paused;
	}

	@keyframes music {
		0% {
			transform: rotate(0deg);
		}

		100% {
			transform: rotate(360deg);
		}

	}

	.baodi-view {
		width: 750rpx;
		padding: 30rpx;
		box-sizing: border-box;

		.baodi-view-0 {
			display: flex;
			justify-content: space-between;
			font-size: 32rpx;
			color: #000;
		}

		.baodi-view-1 {
			padding: 10rpx 0;
			color: #579be2;
			font-size: 26rpx;
			margin-top: 20rpx;
		}

		.baodi-view-2 {
			font-size: 22rpx;
			line-height: 36rpx;
			color: #999;
			margin-top: 10rpx;

			text {
				background-color: #dc85b6;
				color: #ffffff;
				padding: 0 4rpx;
			}
		}

		.baodi-view-buttom {
			width: 690rpx;
			height: 80rpx;
			margin: 100rpx auto 40rpx;
			background-color: #2c2c2e;
			color: #fff;
			font-size: 28rpx;
			display: flex;
			justify-content: center;
			align-items: center;
		}
	}

	.fade-enter-active,
	.fade-leave-active {
		transition: opacity .8s;
	}

	.fade-enter,
	.fade-leave-to

	/* .fade-leave-active below version 2.1.8 */
		{
		opacity: 0;
	}

	.tong-view {
		height: 80rpx;
		line-height: 80rpx;
		position: fixed;
		top: 170rpx;
		width: 750rpx;
		text-align: center;
		z-index: 99999999;
		background-size: 100% 100%;

		.tong-view-text {
			width: 80%;
			color: #fff;
			overflow: hidden;
			white-space: nowrap;
			text-overflow: ellipsis;
			margin: 0 auto;
		}

		.tong-gd-img {
			width: 100rpx;
			height: 100rpx;
			position: absolute;
			top: -10rpx;
			right: 10rpx;
		}

		.text-gd-img {
			height: 60rpx;
			position: absolute;
			top: 26rpx;
			right: 30rpx;
			z-index: 999999999;
			transform: rotate(-8deg);
			font-family: YouSheBiaTiHei;
			color: #a191f3;
			font-size: 50rpx;
			text-shadow: .25rem .125rem .375rem #fff;
			/* #ifdef MP-WEIXIN */
			font-weight: bold;
			text-shadow: .375rem .125rem .375rem #fff;

			/* #endif */
			image {
				width: 55rpx;
				height: 35rpx;
			}

			// mix-blend-mode: multiply;
		}
	}

	.tong-view-ssbg {
		background-image: url("http://v3mh6.oss-cn-beijing.aliyuncs.com/uploads/20240110/6236505eb250653e2d5022ecbbcccec6.png");
	}

	.tong-view-csbg {
		background-image: url("http://v3mh6.oss-cn-beijing.aliyuncs.com/uploads/20240110/3e03b47dd44c18741359433429398637.png");
	}

	.payrow-right {
		text {
			color: red;
			margin-right: 10rpx;
		}
	}

	.xyb-popup {
		background-color: #f1f0f5;

		.xyb-popup-title {
			background-color: #ffffff;
			width: 750rpx;
			box-sizing: border-box;
			height: 100rpx;
			line-height: 100rpx;
			text-align: center;
			font-size: 32rpx;
			font-weight: bold;
			position: relative;

			.xyb-close {
				position: absolute;
				right: 30rpx;
				top: 30rpx;
			}

			text {
				font-size: 22rpx;
			}
		}

		.xyb-popup-cell {
			height: 90rpx;
			width: 690rpx;
			background-color: #ffffff;
			margin: 30rpx auto;
			padding: 0 30rpx;
			box-sizing: border-box;
			display: flex;
			justify-content: space-between;
			align-items: center;
			font-size: 26rpx;
		}

		.xpc-left {
			text {
				color: red
			}
		}

		.no-circle-fill {
			width: 36rpx;
			height: 36rpx;
			border-radius: 50%;
			border: 1px solid #999;
		}

		.xyb-popup-submit {
			width: 690rpx;
			background-color: #313131;
			display: flex;
			justify-content: center;
			align-items: center;
			height: 100rpx;
			margin: 10rpx auto 40rpx;
			color: #fff;
		}
	}

	.mpWxPayPopup {
		width: 100vw;
		height: 100vh;
		display: flex;
		align-items: center;

		.bg {
			width: 630rpx;
			height: 1050rpx;
			background: url("https://sjmanghe.com/imageself/dd_wx_xcx_bg.jpg") no-repeat;
			background-size: 100% 100%;
			margin: 0 auto;
			position: relative;

			.closeImg {
				width: 100rpx;
				height: 95rpx;
				position: absolute;
				left: 502rpx;
				top: 36rpx;
			}

			.qrImg {
				width: 280rpx;
				height: 293rpx;
				position: absolute;
				left: 173rpx;
				top: 430rpx;
			}

			.downImg {
				width: 300rpx;
				height: 95rpx;
				position: absolute;
				left: 163rpx;
				top: 880rpx;
			}
		}
	}

	.qweqwe {
		background-color: #fff;
		width: 100%;
		color: #000;
		margin-top: 25%;
		padding: 20rpx;
		box-sizing: border-box;
	}
	.xieyi {
		width: 690rpx;
		margin: 0 auto;
		padding: 10rpx !important;
		padding-bottom: calc(constant(safe-area-inset-bottom));
		padding-bottom: calc(env(safe-area-inset-bottom));
	}
</style>